Skip to content

Commit

Permalink
split up tests (#3457)
Browse files Browse the repository at this point in the history
Split up the "normal" tests into two groups, and rename the "quick"
tests to "group".
  • Loading branch information
alexcb authored Nov 3, 2023
1 parent 5ac35b6 commit 86e1548
Show file tree
Hide file tree
Showing 5 changed files with 144 additions and 54 deletions.
26 changes: 20 additions & 6 deletions .github/workflows/ci-docker-satellites.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,11 +60,11 @@ jobs:
EARTHLY_ORG: "earthly-technologies"
secrets: inherit

docker-tests-no-qemu-quick1:
docker-tests-no-qemu-group1:
needs: build-earthly
uses: ./.github/workflows/reusable-test.yml
with:
TEST_TARGET: "+test-no-qemu-quick1"
TEST_TARGET: "+test-no-qemu-group1"
BUILT_EARTHLY_PATH: "./build/linux/amd64/earthly"
RUNS_ON: "ubuntu-latest"
BINARY: "docker"
Expand All @@ -74,11 +74,11 @@ jobs:
EARTHLY_ORG: "earthly-technologies"
secrets: inherit

docker-tests-no-qemu-quick2:
docker-tests-no-qemu-group2:
needs: build-earthly
uses: ./.github/workflows/reusable-test.yml
with:
TEST_TARGET: "+test-no-qemu-quick2"
TEST_TARGET: "+test-no-qemu-group2"
BUILT_EARTHLY_PATH: "./build/linux/amd64/earthly"
RUNS_ON: "ubuntu-latest"
BINARY: "docker"
Expand All @@ -88,11 +88,25 @@ jobs:
EARTHLY_ORG: "earthly-technologies"
secrets: inherit

docker-tests-no-qemu-normal:
docker-tests-no-qemu-group3:
needs: build-earthly
uses: ./.github/workflows/reusable-test.yml
with:
TEST_TARGET: "+test-no-qemu-normal"
TEST_TARGET: "+test-no-qemu-group3"
BUILT_EARTHLY_PATH: "./build/linux/amd64/earthly"
RUNS_ON: "ubuntu-latest"
BINARY: "docker"
SUDO: ""
USE_SATELLITE: true
SATELLITE_NAME: "core-test"
EARTHLY_ORG: "earthly-technologies"
secrets: inherit

docker-tests-no-qemu-group4:
needs: build-earthly
uses: ./.github/workflows/reusable-test.yml
with:
TEST_TARGET: "+test-no-qemu-group4"
BUILT_EARTHLY_PATH: "./build/linux/amd64/earthly"
RUNS_ON: "ubuntu-latest"
BINARY: "docker"
Expand Down
102 changes: 78 additions & 24 deletions .github/workflows/ci-docker-ubuntu.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,38 +66,38 @@ jobs:
SKIP_JOB: ${{ needs.build-earthly.result != 'success' }}
secrets: inherit

docker-tests-no-qemu-quick1:
docker-tests-no-qemu-group1:
needs: build-earthly
if: ${{ !failure() }}
uses: ./.github/workflows/reusable-test.yml
with:
TEST_TARGET: "+test-no-qemu-quick1"
TEST_TARGET: "+test-no-qemu-group1"
BUILT_EARTHLY_PATH: "./build/linux/amd64/earthly"
RUNS_ON: "ubuntu-latest"
BINARY: "docker"
SUDO: ""
SKIP_JOB: ${{ needs.build-earthly.result != 'success' }}
secrets: inherit

docker-tests-no-qemu-quick2:
docker-tests-no-qemu-group2:
needs: build-earthly
if: ${{ !failure() }}
uses: ./.github/workflows/reusable-test.yml
with:
TEST_TARGET: "+test-no-qemu-quick2"
TEST_TARGET: "+test-no-qemu-group2"
BUILT_EARTHLY_PATH: "./build/linux/amd64/earthly"
RUNS_ON: "ubuntu-latest"
BINARY: "docker"
SUDO: ""
SKIP_JOB: ${{ needs.build-earthly.result != 'success' }}
secrets: inherit

docker-tests-no-qemu-quick1-no-logbus:
docker-tests-no-qemu-group1-no-logbus:
needs: build-earthly
if: ${{ !failure() }}
uses: ./.github/workflows/reusable-test.yml
with:
TEST_TARGET: "+test-no-qemu-quick1"
TEST_TARGET: "+test-no-qemu-group1"
BUILT_EARTHLY_PATH: "./build/linux/amd64/earthly"
RUNS_ON: "ubuntu-latest"
BINARY: "docker"
Expand All @@ -106,12 +106,12 @@ jobs:
SKIP_JOB: ${{ needs.build-earthly.result != 'success' }}
secrets: inherit

docker-tests-no-qemu-quick2-no-logbus:
docker-tests-no-qemu-group2-no-logbus:
needs: build-earthly
if: ${{ !failure() }}
uses: ./.github/workflows/reusable-test.yml
with:
TEST_TARGET: "+test-no-qemu-quick2"
TEST_TARGET: "+test-no-qemu-group2"
BUILT_EARTHLY_PATH: "./build/linux/amd64/earthly"
RUNS_ON: "ubuntu-latest"
BINARY: "docker"
Expand All @@ -120,25 +120,52 @@ jobs:
SKIP_JOB: ${{ needs.build-earthly.result != 'success' }}
secrets: inherit

docker-tests-no-qemu-normal:
docker-tests-no-qemu-group3:
needs: build-earthly
if: ${{ !failure() }}
uses: ./.github/workflows/reusable-test.yml
with:
TEST_TARGET: "+test-no-qemu-normal"
TEST_TARGET: "+test-no-qemu-group3"
BUILT_EARTHLY_PATH: "./build/linux/amd64/earthly"
RUNS_ON: "ubuntu-latest"
BINARY: "docker"
SUDO: ""
SKIP_JOB: ${{ needs.build-earthly.result != 'success' }}
secrets: inherit

docker-tests-no-qemu-normal-no-logbus:
docker-tests-no-qemu-group3-no-logbus:
needs: build-earthly
if: ${{ !failure() }}
uses: ./.github/workflows/reusable-test.yml
with:
TEST_TARGET: "+test-no-qemu-normal"
TEST_TARGET: "+test-no-qemu-group3"
BUILT_EARTHLY_PATH: "./build/linux/amd64/earthly"
RUNS_ON: "ubuntu-latest"
BINARY: "docker"
SUDO: ""
EXTRA_ARGS: "--logstream=false --logstream-upload=false"
SKIP_JOB: ${{ needs.build-earthly.result != 'success' }}
secrets: inherit

docker-tests-no-qemu-group4:
needs: build-earthly
if: ${{ !failure() }}
uses: ./.github/workflows/reusable-test.yml
with:
TEST_TARGET: "+test-no-qemu-group4"
BUILT_EARTHLY_PATH: "./build/linux/amd64/earthly"
RUNS_ON: "ubuntu-latest"
BINARY: "docker"
SUDO: ""
SKIP_JOB: ${{ needs.build-earthly.result != 'success' }}
secrets: inherit

docker-tests-no-qemu-group4-no-logbus:
needs: build-earthly
if: ${{ !failure() }}
uses: ./.github/workflows/reusable-test.yml
with:
TEST_TARGET: "+test-no-qemu-group4"
BUILT_EARTHLY_PATH: "./build/linux/amd64/earthly"
RUNS_ON: "ubuntu-latest"
BINARY: "docker"
Expand Down Expand Up @@ -385,7 +412,7 @@ jobs:
TARGET_NAME: "+test-quick"
secrets: inherit

docker-wait-block-no-qemu-quick1:
docker-wait-block-no-qemu-group1:
needs: build-earthly
if: ${{ !failure() }}
uses: ./.github/workflows/reusable-wait-block-target.yml
Expand All @@ -395,10 +422,10 @@ jobs:
BINARY: "docker"
SUDO: ""
SKIP_JOB: ${{ needs.build-earthly.result != 'success' }}
TARGET_NAME: "+test-no-qemu-quick1"
TARGET_NAME: "+test-no-qemu-group1"
secrets: inherit

docker-wait-block-no-qemu-quick2:
docker-wait-block-no-qemu-group2:
needs: build-earthly
if: ${{ !failure() }}
uses: ./.github/workflows/reusable-wait-block-target.yml
Expand All @@ -408,10 +435,10 @@ jobs:
BINARY: "docker"
SUDO: ""
SKIP_JOB: ${{ needs.build-earthly.result != 'success' }}
TARGET_NAME: "+test-no-qemu-quick2"
TARGET_NAME: "+test-no-qemu-group2"
secrets: inherit

docker-wait-block-no-qemu-normal:
docker-wait-block-no-qemu-group3:
needs: build-earthly
if: ${{ !failure() }}
uses: ./.github/workflows/reusable-wait-block-target.yml
Expand All @@ -421,7 +448,20 @@ jobs:
BINARY: "docker"
SUDO: ""
SKIP_JOB: ${{ needs.build-earthly.result != 'success' }}
TARGET_NAME: "+test-no-qemu-normal"
TARGET_NAME: "+test-no-qemu-group3"
secrets: inherit

docker-wait-block-no-qemu-group4:
needs: build-earthly
if: ${{ !failure() }}
uses: ./.github/workflows/reusable-wait-block-target.yml
with:
BUILT_EARTHLY_PATH: "./build/linux/amd64/earthly"
RUNS_ON: "ubuntu-latest"
BINARY: "docker"
SUDO: ""
SKIP_JOB: ${{ needs.build-earthly.result != 'success' }}
TARGET_NAME: "+test-no-qemu-group4"
secrets: inherit

docker-wait-block-no-qemu-slow:
Expand Down Expand Up @@ -476,41 +516,55 @@ jobs:
SKIP_JOB: ${{ needs.build-earthly.result != 'success' }}
secrets: inherit

race-tests-no-qemu-quick1:
race-tests-no-qemu-group1:
needs: build-earthly
if: ${{ !failure() }}
uses: ./.github/workflows/reusable-race-test.yml
with:
BUILT_EARTHLY_PATH: "./build/linux/amd64/earthly"
TEST_TARGET: "+test-no-qemu-group1"
RUNS_ON: "ubuntu-latest"
USE_QEMU: false
BINARY: "docker"
SUDO: ""
SKIP_JOB: ${{ needs.build-earthly.result != 'success' }}
secrets: inherit

race-tests-no-qemu-group2:
needs: build-earthly
if: ${{ !failure() }}
uses: ./.github/workflows/reusable-race-test.yml
with:
BUILT_EARTHLY_PATH: "./build/linux/amd64/earthly"
TEST_TARGET: "+test-no-qemu-quick1"
TEST_TARGET: "+test-no-qemu-group2"
RUNS_ON: "ubuntu-latest"
USE_QEMU: false
BINARY: "docker"
SUDO: ""
SKIP_JOB: ${{ needs.build-earthly.result != 'success' }}
secrets: inherit

race-tests-no-qemu-quick2:
race-tests-no-qemu-group3:
needs: build-earthly
if: ${{ !failure() }}
uses: ./.github/workflows/reusable-race-test.yml
with:
BUILT_EARTHLY_PATH: "./build/linux/amd64/earthly"
TEST_TARGET: "+test-no-qemu-quick2"
TEST_TARGET: "+test-no-qemu-group3"
RUNS_ON: "ubuntu-latest"
USE_QEMU: false
BINARY: "docker"
SUDO: ""
SKIP_JOB: ${{ needs.build-earthly.result != 'success' }}
secrets: inherit

race-tests-no-qemu-normal:
race-tests-no-qemu-group4:
needs: build-earthly
if: ${{ !failure() }}
uses: ./.github/workflows/reusable-race-test.yml
with:
BUILT_EARTHLY_PATH: "./build/linux/amd64/earthly"
TEST_TARGET: "+test-no-qemu-normal"
TEST_TARGET: "+test-no-qemu-group4"
RUNS_ON: "ubuntu-latest"
USE_QEMU: false
BINARY: "docker"
Expand Down
25 changes: 19 additions & 6 deletions .github/workflows/ci-podman-ubuntu.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,38 +66,51 @@ jobs:
SKIP_JOB: ${{ needs.build-earthly.result != 'success' }}
secrets: inherit

podman-tests-no-qemu-quick1:
podman-tests-no-qemu-group1:
needs: build-earthly
if: ${{ !failure() }}
uses: ./.github/workflows/reusable-test.yml
with:
TEST_TARGET: "+test-no-qemu-quick1"
TEST_TARGET: "+test-no-qemu-group1"
BUILT_EARTHLY_PATH: "./build/linux/amd64/earthly"
RUNS_ON: "ubuntu-latest"
BINARY: "podman"
SUDO: "sudo -E"
SKIP_JOB: ${{ needs.build-earthly.result != 'success' }}
secrets: inherit

podman-tests-no-qemu-quick2:
podman-tests-no-qemu-group2:
needs: build-earthly
if: ${{ !failure() }}
uses: ./.github/workflows/reusable-test.yml
with:
TEST_TARGET: "+test-no-qemu-quick2"
TEST_TARGET: "+test-no-qemu-group2"
BUILT_EARTHLY_PATH: "./build/linux/amd64/earthly"
RUNS_ON: "ubuntu-latest"
BINARY: "podman"
SUDO: "sudo -E"
SKIP_JOB: ${{ needs.build-earthly.result != 'success' }}
secrets: inherit

podman-tests-no-qemu-normal:
podman-tests-no-qemu-group3:
needs: build-earthly
if: ${{ !failure() }}
uses: ./.github/workflows/reusable-test.yml
with:
TEST_TARGET: "+test-no-qemu-normal"
TEST_TARGET: "+test-no-qemu-group3"
BUILT_EARTHLY_PATH: "./build/linux/amd64/earthly"
RUNS_ON: "ubuntu-latest"
BINARY: "podman"
SUDO: "sudo -E"
SKIP_JOB: ${{ needs.build-earthly.result != 'success' }}
secrets: inherit

podman-tests-no-qemu-group4:
needs: build-earthly
if: ${{ !failure() }}
uses: ./.github/workflows/reusable-test.yml
with:
TEST_TARGET: "+test-no-qemu-group4"
BUILT_EARTHLY_PATH: "./build/linux/amd64/earthly"
RUNS_ON: "ubuntu-latest"
BINARY: "podman"
Expand Down
30 changes: 18 additions & 12 deletions Earthfile
Original file line number Diff line number Diff line change
Expand Up @@ -693,9 +693,10 @@ lint-docs:
# using secure docker hub mirror configurations
test-no-qemu:
BUILD --pass-args +test-quick
BUILD --pass-args +test-no-qemu-quick1
BUILD --pass-args +test-no-qemu-quick2
BUILD --pass-args +test-no-qemu-normal
BUILD --pass-args +test-no-qemu-group1
BUILD --pass-args +test-no-qemu-group2
BUILD --pass-args +test-no-qemu-group3
BUILD --pass-args +test-no-qemu-group4
BUILD --pass-args +test-no-qemu-slow

# test-quick runs the unit, chaos, offline, and go tests and ensures the earthly script does not write to stdout
Expand All @@ -706,19 +707,24 @@ test-quick:
BUILD +earthly-script-no-stdout
BUILD --pass-args ./ast/tests+all

# test-no-qemu-quick1 runs the tests from ./tests+ga-no-qemu-quick1
test-no-qemu-quick1:
BUILD --pass-args ./tests+ga-no-qemu-quick1 \
# test-no-qemu-group1 runs the tests from ./tests+ga-no-qemu-group1
test-no-qemu-group1:
BUILD --pass-args ./tests+ga-no-qemu-group1 \
--GLOBAL_WAIT_END="$GLOBAL_WAIT_END"

# test-no-qemu-quick2 runs the tests from ./tests+ga-no-qemu-quick2
test-no-qemu-quick2:
BUILD --pass-args ./tests+ga-no-qemu-quick2 \
# test-no-qemu-group2 runs the tests from ./tests+ga-no-qemu-group2
test-no-qemu-group2:
BUILD --pass-args ./tests+ga-no-qemu-group2 \
--GLOBAL_WAIT_END="$GLOBAL_WAIT_END"

# test-no-qemu-normal runs the tests from ./tests+ga-no-qemu-normal
test-no-qemu-normal:
BUILD --pass-args ./tests+ga-no-qemu-normal \
# test-no-qemu-group3 runs the tests from ./tests+ga-no-qemu-group3
test-no-qemu-group3:
BUILD --pass-args ./tests+ga-no-qemu-group3 \
--GLOBAL_WAIT_END="$GLOBAL_WAIT_END"

# test-no-qemu-group4 runs the tests from ./tests+ga-no-qemu-group4
test-no-qemu-group4:
BUILD --pass-args ./tests+ga-no-qemu-group4 \
--GLOBAL_WAIT_END="$GLOBAL_WAIT_END"

# test-no-qemu-slow runs the tests from ./tests+ga-no-qemu-slow
Expand Down
Loading

0 comments on commit 86e1548

Please sign in to comment.