Skip to content

Fix unit tests and staticcheck - #199

Merged
daniel-de-vera merged 2 commits into
mainfrom
fix-unit-tests-staticcheck
Jul 30, 2025
Merged

daniel-de-vera merged 2 commits into
mainfrom
fix-unit-tests-staticcheck

Conversation

@daniel-de-vera

Copy link
Copy Markdown
Contributor

This PR fixes:

  • The unit tests:
$ go test -v ./...
?   	github.com/signadot/cli/cmd/signadot	[no test files]
?   	github.com/signadot/cli/internal/auth	[no test files]
?   	github.com/signadot/cli/internal/buildinfo	[no test files]
?   	github.com/signadot/cli/internal/clio	[no test files]
?   	github.com/signadot/cli/internal/command	[no test files]
?   	github.com/signadot/cli/internal/command/artifact	[no test files]
?   	github.com/signadot/cli/internal/command/auth	[no test files]
?   	github.com/signadot/cli/internal/command/bug	[no test files]
?   	github.com/signadot/cli/internal/command/cluster	[no test files]
?   	github.com/signadot/cli/internal/command/cluster/token	[no test files]
?   	github.com/signadot/cli/internal/command/hostedtest	[no test files]
?   	github.com/signadot/cli/internal/command/jobrunnergroup	[no test files]
?   	github.com/signadot/cli/internal/command/jobs	[no test files]
?   	github.com/signadot/cli/internal/command/local	[no test files]
?   	github.com/signadot/cli/internal/command/locald	[no test files]
?   	github.com/signadot/cli/internal/command/logs	[no test files]
?   	github.com/signadot/cli/internal/command/resourceplugin	[no test files]
?   	github.com/signadot/cli/internal/command/routegroup	[no test files]
=== RUN   TestSubst
--- PASS: TestSubst (0.00s)
PASS
ok  	github.com/signadot/cli/internal/command/sandbox	0.020s
?   	github.com/signadot/cli/internal/command/smarttest	[no test files]
?   	github.com/signadot/cli/internal/config	[no test files]
?   	github.com/signadot/cli/internal/hack	[no test files]
?   	github.com/signadot/cli/internal/jsonexact	[no test files]
?   	github.com/signadot/cli/internal/local	[no test files]
?   	github.com/signadot/cli/internal/locald	[no test files]
?   	github.com/signadot/cli/internal/locald/api	[no test files]
?   	github.com/signadot/cli/internal/locald/api/rootmanager	[no test files]
?   	github.com/signadot/cli/internal/locald/api/sandboxmanager	[no test files]
?   	github.com/signadot/cli/internal/locald/rootmanager	[no test files]
?   	github.com/signadot/cli/internal/locald/sandboxmanager	[no test files]
?   	github.com/signadot/cli/internal/poll	[no test files]
?   	github.com/signadot/cli/internal/print	[no test files]
=== RUN   TestLabelAggregation
--- PASS: TestLabelAggregation (0.01s)
=== RUN   TestFileDiscovery
--- PASS: TestFileDiscovery (0.00s)
=== RUN   TestDirectFilePathInConfig
    config_test.go:166: Found file: /home/ddv/git/signadot/cli/tests/fixtures/smart-tests-git/backend/test.star
--- PASS: TestDirectFilePathInConfig (0.00s)
=== RUN   TestGitRepoNormalization
--- PASS: TestGitRepoNormalization (0.00s)
PASS
ok  	github.com/signadot/cli/internal/repoconfig	0.018s
=== RUN   FuzzTruncate
=== RUN   FuzzTruncate/seed#0
=== RUN   FuzzTruncate/seed#1
=== RUN   FuzzTruncate/seed#2
=== RUN   FuzzTruncate/seed#3
--- PASS: FuzzTruncate (0.00s)
    --- PASS: FuzzTruncate/seed#0 (0.00s)
    --- PASS: FuzzTruncate/seed#1 (0.00s)
    --- PASS: FuzzTruncate/seed#2 (0.00s)
    --- PASS: FuzzTruncate/seed#3 (0.00s)
=== RUN   ExampleTruncate
--- PASS: ExampleTruncate (0.00s)
PASS
ok  	github.com/signadot/cli/internal/sdtab	(cached)
?   	github.com/signadot/cli/internal/shallow	[no test files]
?   	github.com/signadot/cli/internal/spinner	[no test files]
=== RUN   TestTemplating
--- PASS: TestTemplating (0.00s)
PASS
ok  	github.com/signadot/cli/internal/utils	(cached)
?   	github.com/signadot/cli/internal/utils/system	[no test files]
  • The issues reported by staticcheck:
$ staticcheck ./... 
$ 
  • A local dependency introduced by prev commit:

cli/go.mod

Lines 144 to 147 in 08165f6

// Used for local dev
// replace github.com/signadot/libconnect => ../libconnect/
replace github.com/signadot/go-sdk => ../go-sdk

@scott-cotton scott-cotton left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM thanks!

@daniel-de-vera
daniel-de-vera merged commit 53909dc into main Jul 30, 2025
@daniel-de-vera
daniel-de-vera deleted the fix-unit-tests-staticcheck branch July 30, 2025 18:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants