Skip to content

Commit

Permalink
Call basename, since project root has a timestamp.
Browse files Browse the repository at this point in the history
  • Loading branch information
mbomb007 committed May 22, 2024
1 parent 4758824 commit 9dd8aee
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pkg/ddevapp/config_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -233,8 +233,7 @@ func TestConfigCommand(t *testing.T) {
}

for testName, testValues := range testMatrix {
projectRoot := t.Name() + "_" + testName
testDir := testcommon.CreateTmpDir(projectRoot)
testDir := testcommon.CreateTmpDir(t.Name() + "_" + testName)

// Create a docroot folder.
err := os.Mkdir(filepath.Join(testDir, "docroot"), 0644)
Expand Down Expand Up @@ -270,6 +269,7 @@ func TestConfigCommand(t *testing.T) {
out := restoreOutput()

// Ensure we have expected vales in output.
projectRoot := basename(testDir)

Check failure on line 272 in pkg/ddevapp/config_test.go

View workflow job for this annotation

GitHub Actions / Lint Go Files

undefined: basename (typecheck)

Check failure on line 272 in pkg/ddevapp/config_test.go

View workflow job for this annotation

GitHub Actions / tests (apache-fpm, apache-fpm)

undefined: basename

Check failure on line 272 in pkg/ddevapp/config_test.go

View workflow job for this annotation

GitHub Actions / tests (nginx-fpm, nginx-fpm)

undefined: basename

Check failure on line 272 in pkg/ddevapp/config_test.go

View workflow job for this annotation

GitHub Actions / tests (mutagen, true)

undefined: basename

Check failure on line 272 in pkg/ddevapp/config_test.go

View workflow job for this annotation

GitHub Actions / tests (nginx-proxy, nginx-proxy)

undefined: basename

Check failure on line 272 in pkg/ddevapp/config_test.go

View workflow job for this annotation

GitHub Actions / tests (pull-push-test-platforms, true)

undefined: basename

Check failure on line 272 in pkg/ddevapp/config_test.go

View workflow job for this annotation

GitHub Actions / tests (race-detection, true)

undefined: basename
assert.Contains(out, testDir)
assert.NotContains(out, fmt.Sprintf("%s is not a valid project name", projectRoot))

Expand Down

0 comments on commit 9dd8aee

Please sign in to comment.