Skip to content

Commit 02e8c77

Browse files
authored
[skip-changelog] Fix integration test intermittent failure due to download/file in use (#1905)
* Do not run go integration tests in parallel This is required since the integration tests shares the download folder. Still not ideal, it would be better if the cli could handle concurrent access to the download folder (from multiple cli processes...), but at least allows to run the tests without random failures. * Fixed integration test
1 parent 3d5a87e commit 02e8c77

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

Diff for: Taskfile.yml

+2
Original file line numberDiff line numberDiff line change
@@ -95,10 +95,12 @@ tasks:
9595
- task: go:build
9696
dir: '{{default "./" .GO_MODULE_PATH}}'
9797
cmds:
98+
# "-p 1" will not run test in parallel, this is required for integration tests
9899
- |
99100
go test \
100101
-v \
101102
-short \
103+
-p 1 \
102104
-run '{{default ".*" .GO_TEST_REGEX}}' \
103105
{{default "-timeout 10m -coverpkg=./... -covermode=atomic" .GO_TEST_FLAGS}} \
104106
-coverprofile=coverage_unit.txt \

Diff for: internal/integrationtest/upgrade/upgrade_test.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,9 @@ func TestUpgrade(t *testing.T) {
2828
defer env.CleanUp()
2929

3030
// Updates index for cores and libraries
31-
_, _, err := cli.Run("core", "update-idex")
31+
_, _, err := cli.Run("core", "update-index")
3232
require.NoError(t, err)
33-
_, _, err = cli.Run("lib", "update-idex")
33+
_, _, err = cli.Run("lib", "update-index")
3434
require.NoError(t, err)
3535

3636
// Installs an outdated core and library

0 commit comments

Comments
 (0)