Skip to content
Myr

Fixed tests for how they are run

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Jared Bydeley · committed by Steve Francia · parent 3e7fb99 · Browse files · 1 file+3 added−5 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+3 added−5 removed

  • other:+3 added−5 removed

1 file+3 added−5 removed

modified:cobra/cmd/helpers_test.go+3 added-5 removed
27 unmodified lines
28 projectPath = ""29}3031func TestProjectPath(t *testing.T) {32 wd, _ := os.Getwd()3334 checkGuess(t, "", "github.com/spf13/hugo", filepath.Join(wd, "github.com", "spf13", "hugo"))35 checkGuess(t, "", "spf13/hugo", filepath.Join(wd, "spf13", "hugo"))36 checkGuess(t, "", "/bar/foo", filepath.Join(wd, "bar", "foo"))32 checkGuess(t, "", filepath.Join("github.com", "spf13", "hugo"), filepath.Join(getSrcPath(), "github.com", "spf13", "hugo"))33 checkGuess(t, "", filepath.Join("spf13", "hugo"), filepath.Join(getSrcPath(), "github.com", "spf13", "hugo"))34 checkGuess(t, "", filepath.Join("/", "bar", "foo"), filepath.Join(getSrcPath(), "bar", "foo"))35 checkGuess(t, "/bar/foo", "baz", filepath.Join("/", "bar", "foo", "baz"))36 checkGuess(t, "/bar/foo/cmd", "", filepath.Join("/", "bar", "foo"))37 checkGuess(t, "/bar/foo/command", "", filepath.Join("/", "bar", "foo"))38 checkGuess(t, "/bar/foo/commands", "", filepath.Join("/", "bar", "foo"))
2 unmodified lines