Skip to content

Commit 5f07ced

Browse files
authored
Fix use of "contraints" package and update GitHub action
* Update go.yml * Fix comparison.go use of constraints
1 parent d21f3f5 commit 5f07ced

File tree

4 files changed

+12
-12
lines changed

4 files changed

+12
-12
lines changed

.github/workflows/go.yml

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -15,26 +15,21 @@ jobs:
1515
- name: Set up Go
1616
uses: actions/setup-go@v2
1717
with:
18-
go-version: 1.17
19-
20-
- name: Install Go 1.18
21-
run: |
22-
go install golang.org/dl/go1.18beta1@latest
23-
go1.18beta1 download
18+
go-version: 1.18
2419

2520
- name: Build
26-
run: go1.18beta1 build -v ./...
21+
run: go build -v ./...
2722

2823
- name: Test
29-
run: go1.18beta1 test -v ./...
24+
run: go test -v ./...
3025

3126
- name: Calcualte coverage
3227
run: |
33-
go1.18beta1 test -v -covermode=count -coverprofile=coverage.out
28+
go test -v -covermode=count -coverprofile=coverage.out
3429
- name: Convert coverage.out to coverage.lcov
3530
uses: jandelgado/[email protected]
3631
- name: Coveralls
3732
uses: coverallsapp/[email protected]
3833
with:
3934
github-token: ${{ secrets.github_token }}
40-
path-to-lcov: coverage.lcov
35+
path-to-lcov: coverage.lcov

comparison.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
package tuple
22

33
import (
4-
"constraints"
4+
"golang.org/x/exp/constraints"
55
)
66

77
// OrderedComparisonResult represents the result of a tuple ordered comparison.

go.mod

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,10 @@ module github.com/barweiss/go-tuple
22

33
go 1.18
44

5-
require github.com/stretchr/testify v1.7.0
5+
require (
6+
github.com/stretchr/testify v1.7.0
7+
golang.org/x/exp v0.0.0-20220314205449-43aec2f8a4e7
8+
)
69

710
require (
811
github.com/davecgh/go-spew v1.1.0 // indirect

go.sum

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@ github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZN
55
github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
66
github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5CcY=
77
github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
8+
golang.org/x/exp v0.0.0-20220314205449-43aec2f8a4e7 h1:jynE66seADJbyWMUdeOyVTvPtBZt7L6LJHupGwxPZRM=
9+
golang.org/x/exp v0.0.0-20220314205449-43aec2f8a4e7/go.mod h1:lgLbSvA5ygNOMpwM/9anMpWVlVJ7Z+cHWq/eFuinpGE=
810
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM=
911
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
1012
gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c h1:dUUwHk2QECo/6vqA44rthZ8ie2QXMNeKRTHCNY2nXvo=

0 commit comments

Comments
 (0)