Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ jobs:
- uses: golangci/golangci-lint-action@v3
with:
version: v1.55.2
args: --timeout 5m
args: --verbose
skip-cache: true
- name: Test
run: go test ./...
18 changes: 17 additions & 1 deletion .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ linters:
- misspell
- nakedret
- revive
- testifylint
linters-settings:
gocritic:
# Enable multiple checks by tags, run `GL_DEBUG=gocritic golangci-lint run` to see all tags and checks.
Expand All @@ -34,5 +35,20 @@ linters-settings:
recommendations:
- errors
- fmt
testifylint:
disable:
- float-compare
- go-require
enable:
- bool-compare
- compares
- empty
- error-is-as
- error-nil
- expected-actual
- len
- require-error
- suite-dont-use-pkg
- suite-extra-assert-call
run:
timeout: 2m
timeout: 5m
5 changes: 3 additions & 2 deletions dotenv/godotenv_var_expansion_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import (

"github.com/compose-spec/compose-go/v2/template"
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require"
)

var envMap = map[string]string{
Expand Down Expand Up @@ -43,7 +44,7 @@ func TestExpandIfEmptyOrUnset(t *testing.T) {
for _, expected := range templateResults {
t.Run(expected.name, func(t *testing.T) {
result, err := expandVariables(expected.input, envMap, notFoundLookup)
assert.Nil(t, err)
require.NoError(t, err)
assert.Equal(t, result, expected.result)
})
}
Expand Down Expand Up @@ -75,7 +76,7 @@ func TestExpandIfUnset(t *testing.T) {
for _, expected := range templateResults {
t.Run(expected.name, func(t *testing.T) {
result, err := expandVariables(expected.input, envMap, notFoundLookup)
assert.Nil(t, err)
require.NoError(t, err)
assert.Equal(t, result, expected.result)
})
}
Expand Down