fix repo path
This commit is contained in:
parent
965b9a3b0a
commit
f3b42297d4
8
Makefile
Normal file
8
Makefile
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
LDFLAGS?=--ldflags '-extldflags "-static"' --ldflags="-X 'main.commit=$(shell git rev-parse HEAD)' -X 'main.version=$(shell git describe --tags)' -X 'main.date=$(shell date '+%Y-%m-%d %T.%s%z')'"
|
||||||
|
export CGO_ENABLED=0
|
||||||
|
|
||||||
|
build-run:
|
||||||
|
docker run -v $(shell pwd):/code -w /code -it registry.cv.mazarbul.net/declarative/build-golang:1.22.1-alpine-x86_64 sh
|
||||||
|
test:
|
||||||
|
go test -coverprofile=artifacts/coverage.profile ./...
|
||||||
|
go tool cover -html=artifacts/coverage.profile -o artifacts/code-coverage.html
|
@ -1,10 +1,11 @@
|
|||||||
// Copyright 2024 Matthew Rich <matthewrich.conf@gmail.com>. All rights reserved.
|
// Copyright 2024 Matthew Rich <matthewrich.conf@gmail.com>. All rights reserved.
|
||||||
|
|
||||||
package fixture_test
|
package fixture_test
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"testing"
|
"testing"
|
||||||
"math"
|
"math"
|
||||||
"gitea.cv.mazarbul.net/rosskeen.house/testing/fixture"
|
"testing/fixture"
|
||||||
)
|
)
|
||||||
|
|
||||||
func Fixture2Pow(p fixture.Param) interface{} {
|
func Fixture2Pow(p fixture.Param) interface{} {
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
// Copyright 2024 Matthew Rich <matthewrich.conf@gmail.com>. All rights reserved.
|
// Copyright 2024 Matthew Rich <matthewrich.conf@gmail.com>. All rights reserved.
|
||||||
|
|
||||||
package mockdata
|
package mockdata
|
||||||
|
|
||||||
import (
|
import (
|
||||||
@ -9,7 +10,7 @@ import (
|
|||||||
// "fmt"
|
// "fmt"
|
||||||
// "strings"
|
// "strings"
|
||||||
// "strconv"
|
// "strconv"
|
||||||
"gitea.cv.mazarbul.net/rosskeen.house/testing/fixture"
|
"testing/fixture"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Raw file fixture data
|
// Raw file fixture data
|
||||||
|
@ -1,10 +1,11 @@
|
|||||||
// Copyright 2024 Matthew Rich <matthewrich.conf@gmail.com>. All rights reserved.
|
// Copyright 2024 Matthew Rich <matthewrich.conf@gmail.com>. All rights reserved.
|
||||||
|
|
||||||
package mockdata_test
|
package mockdata_test
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"testing"
|
"testing"
|
||||||
"gitea.cv.mazarbul.net/rosskeen.house/testing/fixture"
|
"testing/fixture"
|
||||||
"gitea.cv.mazarbul.net/rosskeen.house/testing/md"
|
"testing/md"
|
||||||
)
|
)
|
||||||
|
|
||||||
type MockDataTest struct {
|
type MockDataTest struct {
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
// Copyright 2024 Matthew Rich <matthewrich.conf@gmail.com>. All rights reserved.
|
// Copyright 2024 Matthew Rich <matthewrich.conf@gmail.com>. All rights reserved.
|
||||||
|
|
||||||
package mockdata
|
package mockdata
|
||||||
|
|
||||||
import (
|
import (
|
||||||
@ -7,7 +8,7 @@ import (
|
|||||||
"gopkg.in/yaml.v2"
|
"gopkg.in/yaml.v2"
|
||||||
"log"
|
"log"
|
||||||
"fmt"
|
"fmt"
|
||||||
"gitea.cv.mazarbul.net/rosskeen.house/testing/fixture"
|
"testing/fixture"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Return a structure to load the mock data into
|
// Return a structure to load the mock data into
|
||||||
|
@ -1,11 +1,12 @@
|
|||||||
// Copyright 2024 Matthew Rich <matthewrich.conf@gmail.com>. All rights reserved.
|
// Copyright 2024 Matthew Rich <matthewrich.conf@gmail.com>. All rights reserved.
|
||||||
|
|
||||||
package mockdata
|
package mockdata
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"path/filepath"
|
"path/filepath"
|
||||||
"log"
|
"log"
|
||||||
"fmt"
|
"fmt"
|
||||||
"gitea.cv.mazarbul.net/rosskeen.house/testing/fixture"
|
"testing/fixture"
|
||||||
)
|
)
|
||||||
|
|
||||||
type Results struct {
|
type Results struct {
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
// Copyright 2024 Matthew Rich <matthewrich.conf@gmail.com>. All rights reserved.
|
// Copyright 2024 Matthew Rich <matthewrich.conf@gmail.com>. All rights reserved.
|
||||||
|
|
||||||
package testdata
|
package testdata
|
||||||
|
|
||||||
import (
|
import (
|
||||||
@ -6,7 +7,7 @@ import (
|
|||||||
"path/filepath"
|
"path/filepath"
|
||||||
"log"
|
"log"
|
||||||
"fmt"
|
"fmt"
|
||||||
"gitea.cv.mazarbul.net/rosskeen.house/testing/fixture"
|
"testing/fixture"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
|
@ -1,11 +1,12 @@
|
|||||||
// Copyright 2024 Matthew Rich <matthewrich.conf@gmail.com>. All rights reserved.
|
// Copyright 2024 Matthew Rich <matthewrich.conf@gmail.com>. All rights reserved.
|
||||||
|
|
||||||
package testdata
|
package testdata
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"path/filepath"
|
"path/filepath"
|
||||||
"log"
|
"log"
|
||||||
"fmt"
|
"fmt"
|
||||||
"gitea.cv.mazarbul.net/rosskeen.house/testing/fixture"
|
"testing/fixture"
|
||||||
)
|
)
|
||||||
|
|
||||||
type TypeConversion func(value interface{}) interface{}
|
type TypeConversion func(value interface{}) interface{}
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
// Copyright 2024 Matthew Rich <matthewrich.conf@gmail.com>. All rights reserved.
|
// Copyright 2024 Matthew Rich <matthewrich.conf@gmail.com>. All rights reserved.
|
||||||
|
|
||||||
package testdata
|
package testdata
|
||||||
|
|
||||||
import (
|
import (
|
||||||
@ -9,7 +10,7 @@ import (
|
|||||||
// "fmt"
|
// "fmt"
|
||||||
// "strings"
|
// "strings"
|
||||||
// "strconv"
|
// "strconv"
|
||||||
"gitea.cv.mazarbul.net/rosskeen.house/testing/fixture"
|
"testing/fixture"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Raw file fixture data
|
// Raw file fixture data
|
||||||
|
@ -1,12 +1,13 @@
|
|||||||
// Copyright 2024 Matthew Rich <matthewrich.conf@gmail.com>. All rights reserved.
|
// Copyright 2024 Matthew Rich <matthewrich.conf@gmail.com>. All rights reserved.
|
||||||
|
|
||||||
package testdata_test
|
package testdata_test
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"testing"
|
"testing"
|
||||||
"strconv"
|
"strconv"
|
||||||
"strings"
|
"strings"
|
||||||
"gitea.cv.mazarbul.net/rosskeen.house/testing/fixture"
|
"testing/fixture"
|
||||||
"gitea.cv.mazarbul.net/rosskeen.house/testing/td"
|
"testing/td"
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestTDFixture(t *testing.T) {
|
func TestTDFixture(t *testing.T) {
|
||||||
|
Loading…
Reference in New Issue
Block a user