Skip to content

Commit c5b0b33

Browse files
kterui9019claude
andcommitted
fix: correct CheckTrue usage in docker-compose test
Fix lint error by replacing t.CheckTrue with proper error checking. CheckTrue only accepts one argument (bool), not a message. Changed from: t.CheckTrue(len(containers) > 0, "message") To: if len(containers) == 0 { t.T.Fatal("message") } This matches the pattern used in other integration tests. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
1 parent 50fd889 commit c5b0b33

File tree

2 files changed

+7
-5
lines changed

2 files changed

+7
-5
lines changed

integration/delete_test.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -180,7 +180,9 @@ func TestDeleteDockerComposeDeployer(t *testing.T) {
180180
// Verify containers are running
181181
client := SetupDockerClient(t.T)
182182
containers := getComposeContainers(ctx, t, "skaffold-", client)
183-
t.CheckTrue(len(containers) > 0, "Expected at least one container to be deployed")
183+
if len(containers) == 0 {
184+
t.T.Fatal("Expected at least one container to be deployed")
185+
}
184186

185187
// Delete the deployment
186188
skaffold.Delete(test.args...).InDir(test.dir).RunOrFail(t.T)

integration/dev_test.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -193,10 +193,10 @@ func TestDevCancelWithDockerComposeDeployer(t *testing.T) {
193193
}
194194

195195
tests := []struct {
196-
description string
197-
dir string
198-
minContainers int
199-
projectPrefix string
196+
description string
197+
dir string
198+
minContainers int
199+
projectPrefix string
200200
}{
201201
{
202202
description: "interrupt dev loop in Docker Compose deployer",

0 commit comments

Comments
 (0)