Skip to content

Commit

Permalink
feat: run tests in parallel again
Browse files Browse the repository at this point in the history
  • Loading branch information
juev committed Dec 11, 2023
1 parent ced134e commit eb3d558
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 18 deletions.
12 changes: 6 additions & 6 deletions gobrew_test.go
Expand Up @@ -26,7 +26,7 @@ func setupGobrew(t *testing.T, ts *httptest.Server) GoBrew {
}

func TestInstallAndExistVersion(t *testing.T) {
//t.Parallel()
t.Parallel()
ts := httptest.NewServer(http.FileServer(http.Dir("testdata")))
defer ts.Close()
gb := setupGobrew(t, ts)
Expand All @@ -37,7 +37,7 @@ func TestInstallAndExistVersion(t *testing.T) {
}

func TestUnInstallThenNotExistVersion(t *testing.T) {
//t.Parallel()
t.Parallel()
ts := httptest.NewServer(http.FileServer(http.Dir("testdata")))
defer ts.Close()
gb := setupGobrew(t, ts)
Expand All @@ -51,7 +51,7 @@ func TestUnInstallThenNotExistVersion(t *testing.T) {
}

func TestUpgrade(t *testing.T) {
//t.Parallel()
t.Parallel()
ts := httptest.NewServer(http.FileServer(http.Dir("testdata")))
defer ts.Close()
gb := setupGobrew(t, ts)
Expand Down Expand Up @@ -102,7 +102,7 @@ func TestDoNotUpgradeLatestVersion(t *testing.T) {
}

func TestInteractive(t *testing.T) {
//t.Parallel()
t.Parallel()
ts := httptest.NewServer(http.FileServer(http.Dir("testdata")))
defer ts.Close()
gb := setupGobrew(t, ts)
Expand Down Expand Up @@ -130,7 +130,7 @@ func TestInteractive(t *testing.T) {
}

func TestPrune(t *testing.T) {
//t.Parallel()
t.Parallel()
ts := httptest.NewServer(http.FileServer(http.Dir("testdata")))
defer ts.Close()
gb := setupGobrew(t, ts)
Expand All @@ -144,7 +144,7 @@ func TestPrune(t *testing.T) {
}

func TestGoBrew_CurrentVersion(t *testing.T) {
//t.Parallel()
t.Parallel()
ts := httptest.NewServer(http.FileServer(http.Dir("testdata")))
defer ts.Close()
gb := setupGobrew(t, ts)
Expand Down
22 changes: 11 additions & 11 deletions helpers_test.go
Expand Up @@ -12,7 +12,7 @@ import (
)

func TestJudgeVersion(t *testing.T) {
//t.Parallel()
t.Parallel()
tests := []struct {
version string
wantVersion string
Expand Down Expand Up @@ -56,7 +56,7 @@ func TestJudgeVersion(t *testing.T) {
for _, test := range tests {
test := test
t.Run(test.version, func(t *testing.T) {
//t.Parallel()
t.Parallel()
ts := httptest.NewServer(http.FileServer(http.Dir("testdata")))
defer ts.Close()
gb := setupGobrew(t, ts)
Expand All @@ -69,7 +69,7 @@ func TestJudgeVersion(t *testing.T) {
}

func TestListVersions(t *testing.T) {
//t.Parallel()
t.Parallel()
ts := httptest.NewServer(http.FileServer(http.Dir("testdata")))
defer ts.Close()
gb := setupGobrew(t, ts)
Expand All @@ -79,7 +79,7 @@ func TestListVersions(t *testing.T) {
}

func TestExistVersion(t *testing.T) {
//t.Parallel()
t.Parallel()
ts := httptest.NewServer(http.FileServer(http.Dir("testdata")))
defer ts.Close()
gb := setupGobrew(t, ts)
Expand All @@ -91,7 +91,7 @@ func TestExistVersion(t *testing.T) {
}

func TestExtractMajorVersion(t *testing.T) {
//t.Parallel()
t.Parallel()
type args struct {
version string
}
Expand Down Expand Up @@ -139,7 +139,7 @@ func TestExtractMajorVersion(t *testing.T) {
for _, tt := range tests {
tt := tt
t.Run(tt.name, func(t *testing.T) {
//t.Parallel()
t.Parallel()
if got := extractMajorVersion(tt.args.version); got != tt.want {
t.Errorf("ExtractMajorVersion() = %v, want %v", got, tt.want)
}
Expand All @@ -149,7 +149,7 @@ func TestExtractMajorVersion(t *testing.T) {
}

func TestGoBrew_extract(t *testing.T) {
//t.Parallel()
t.Parallel()
type args struct {
srcTar string
dstDir string
Expand Down Expand Up @@ -179,7 +179,7 @@ func TestGoBrew_extract(t *testing.T) {
for _, tt := range tests {
tt := tt
t.Run(tt.name, func(t *testing.T) {
//t.Parallel()
t.Parallel()
ts := httptest.NewServer(http.FileServer(http.Dir("testdata")))
defer ts.Close()
gb := setupGobrew(t, ts)
Expand All @@ -192,7 +192,7 @@ func TestGoBrew_extract(t *testing.T) {
}

func Test_doRequest(t *testing.T) {
//t.Parallel()
t.Parallel()
type args struct {
url string
}
Expand All @@ -212,7 +212,7 @@ func Test_doRequest(t *testing.T) {
for _, tt := range tests {
tt := tt
t.Run(tt.name, func(t *testing.T) {
//t.Parallel()
t.Parallel()
ts := httptest.NewServer(http.FileServer(http.Dir("testdata")))
defer ts.Close()
urlGet, _ := url.JoinPath(ts.URL, tt.args.url)
Expand All @@ -225,7 +225,7 @@ func Test_doRequest(t *testing.T) {
}

func TestGoBrew_downloadAndExtract(t *testing.T) {
//t.Parallel()
t.Parallel()
ts := httptest.NewServer(http.FileServer(http.Dir("testdata")))
defer ts.Close()
gb := setupGobrew(t, ts)
Expand Down
2 changes: 1 addition & 1 deletion utils/utils_test.go
Expand Up @@ -8,7 +8,7 @@ import (
)

func TestDownloadWithProgress(t *testing.T) {
//t.Parallel()
t.Parallel()
ts := httptest.NewServer(http.FileServer(http.Dir("../testdata")))
defer ts.Close()
path, _ := url.JoinPath(ts.URL, "go1.9.darwin-arm64.tar.gz")
Expand Down

0 comments on commit eb3d558

Please sign in to comment.