Skip to content

Commit 947fb5b

Browse files
committed
Ci: Don't run non-bootstrapped tests on PRs
They mostly check a subset of things that can be detected with bootstrapped tests, it's still useful to know that everything works without bootstrapping on master so keep those tests on pushed commits and releases.
1 parent e2838e4 commit 947fb5b

File tree

1 file changed

+11
-25
lines changed

1 file changed

+11
-25
lines changed

.github/workflows/ci.yaml

+11-25
Original file line numberDiff line numberDiff line change
@@ -10,17 +10,19 @@ env:
1010
DOTTY_CI_RUN: true
1111

1212
jobs:
13-
test:
13+
test_non_bootstrapped:
1414
runs-on: [self-hosted, Linux]
1515
container:
1616
image: lampepfl/dotty:2020-11-19
1717
volumes:
1818
- ${{ github.workspace }}/../../cache/sbt:/root/.sbt
1919
- ${{ github.workspace }}/../../cache/ivy:/root/.ivy2/cache
2020
- ${{ github.workspace }}/../../cache/general:/root/.cache
21-
if: "!(github.event_name == 'push' &&
22-
startsWith(github.event.ref, 'refs/tags/sbt-dotty-'))"
23-
21+
if: "(
22+
github.event_name == 'push' &&
23+
!startsWith(github.event.ref, 'refs/tags/sbt-dotty-')
24+
) ||
25+
github.event_name == 'schedule')"
2426
steps:
2527
- name: Set JDK 15 as default
2628
run: echo "/usr/lib/jvm/java-15-openjdk-amd64/bin" >> $GITHUB_PATH
@@ -42,7 +44,7 @@ jobs:
4244
./project/scripts/sbt ";compile ;test"
4345
./project/scripts/cmdTests
4446
45-
test_bootstrapped:
47+
test:
4648
runs-on: [self-hosted, Linux]
4749
container:
4850
image: lampepfl/dotty:2020-11-19
@@ -74,23 +76,7 @@ jobs:
7476
./project/scripts/sbt ";scala3-bootstrapped/compile ;scala3-bootstrapped/test;sjsSandbox/run;sjsSandbox/test;sjsJUnitTests/test;sjsCompilerTests/test ;sbt-dotty/scripted scala2-compat/* ;configureIDE ;stdlib-bootstrapped/test:run ;stdlib-bootstrapped-tasty-tests/test"
7577
./project/scripts/bootstrapCmdTests
7678
77-
## Only run bootstrapped tests for Windows since that's a superset of the
78-
## non-bootstrapped tests and bootstrapping issues should be caught by
79-
## the non-bootstrapped Linux runner.
80-
# test-windows:
81-
# runs-on: [self-hosted, Windows]
82-
# if: "!(github.event_name == 'push' &&
83-
# startsWith(github.event.ref, 'refs/tags/sbt-dotty-'))"
84-
85-
# steps:
86-
# - name: Git Checkout
87-
# uses: actions/checkout@v2
88-
89-
# - name: Test
90-
# run: sbt ";compile ;test"
91-
# shell: cmd
92-
93-
test_bootstrapped-windows:
79+
test_windows:
9480
runs-on: [self-hosted, Windows]
9581
if: "!(github.event_name == 'push' &&
9682
startsWith(github.event.ref, 'refs/tags/sbt-dotty-'))"
@@ -193,7 +179,7 @@ jobs:
193179
- name: Test
194180
run: ./project/scripts/sbt sbt-dotty/scripted
195181

196-
test_bootstrapped_java8:
182+
test_java8:
197183
runs-on: [self-hosted, Linux]
198184
container:
199185
image: lampepfl/dotty:2020-11-19
@@ -238,7 +224,7 @@ jobs:
238224
- ${{ github.workspace }}/../../cache/sbt:/root/.sbt
239225
- ${{ github.workspace }}/../../cache/ivy:/root/.ivy2/cache
240226
- ${{ github.workspace }}/../../cache/general:/root/.cache
241-
needs: [test, test_bootstrapped, community_build_a, community_build_b, test_sbt, test_bootstrapped_java8]
227+
needs: [test_non_bootstrapped, test, community_build_a, community_build_b, test_sbt, test_java8]
242228
if: github.event_name == 'schedule'
243229
env:
244230
NIGHTLYBUILD: yes
@@ -313,7 +299,7 @@ jobs:
313299
- ${{ github.workspace }}/../../cache/sbt:/root/.sbt
314300
- ${{ github.workspace }}/../../cache/ivy:/root/.ivy2/cache
315301
- ${{ github.workspace }}/../../cache/general:/root/.cache
316-
needs: [test, test_bootstrapped, community_build_a, community_build_b, test_sbt, test_bootstrapped_java8]
302+
needs: [test_non_bootstrapped, test, community_build_a, community_build_b, test_sbt, test_java8]
317303
if: github.event_name == 'push' &&
318304
startsWith(github.event.ref, 'refs/tags/') &&
319305
!startsWith(github.event.ref, 'refs/tags/sbt-dotty-')

0 commit comments

Comments
 (0)