5151# text on stderr and so can break tests which check the output of a program).
5252
5353jobs :
54+ test :
55+ runs-on : [self-hosted, Linux]
56+ container :
57+ image : lampepfl/dotty:2024-10-18
58+ options : --cpu-shares 4096
59+ volumes :
60+ - ${{ github.workspace }}/../../cache/sbt:/root/.sbt
61+ - ${{ github.workspace }}/../../cache/ivy:/root/.ivy2/cache
62+ - ${{ github.workspace }}/../../cache/general:/root/.cache
63+ if : " github.event_name == 'schedule' && github.repository == 'scala/scala3'
64+ || github.event_name == 'push'
65+ || github.event_name == 'merge_group'
66+ || (
67+ github.event_name == 'pull_request'
68+ && !contains(github.event.pull_request.body, '[skip ci]')
69+ && !contains(github.event.pull_request.body, '[skip test]')
70+ )
71+ || (
72+ github.event_name == 'workflow_dispatch'
73+ && github.repository == 'scala/scala3'
74+ )"
75+
76+ steps :
77+ - name : Set JDK 17 as default
78+ run : echo "/usr/lib/jvm/java-17-openjdk-amd64/bin" >> $GITHUB_PATH
79+
80+ - name : Reset existing repo
81+ run : |
82+ git config --global --add safe.directory $GITHUB_WORKSPACE
83+ git -c "http.https://github.com/.extraheader=" fetch --recurse-submodules=no "https://github.com/scala/scala3" && git reset --hard FETCH_HEAD || true
84+
85+ - name : Checkout cleanup script
86+ uses : actions/checkout@v5
87+
88+ - name : Cleanup
89+ run : .github/workflows/cleanup.sh
90+
91+ - name : Git Checkout
92+ uses : actions/checkout@v5
93+
94+ - name : Add SBT proxy repositories
95+ run : cp -vf .github/workflows/repositories /root/.sbt/ ; true
96+
97+ - name : Cmd Tests
98+ run : |
99+ ./project/scripts/buildScalaBinary
100+ ./project/scripts/sbt ";scala3-bootstrapped/compile ;scala3-bootstrapped/publishLocal ;scala3-compiler-bootstrapped/scala3CompilerCoursierTest:test"
101+ ./project/scripts/cmdTests
102+ ./project/scripts/bootstrappedOnlyCmdTests
103+
104+ test_windows_fast :
105+ runs-on : [self-hosted, Windows]
106+ if : " (
107+ github.event_name == 'push'
108+ && github.ref != 'refs/heads/main'
109+ )
110+ || github.event_name == 'merge_group'
111+ || (
112+ github.event_name == 'pull_request'
113+ && !contains(github.event.pull_request.body, '[skip ci]')
114+ && !contains(github.event.pull_request.body, '[skip test_windows_fast]')
115+ )"
116+
117+ steps :
118+ - name : Reset existing repo
119+ shell : cmd
120+ run : |
121+ git config --global --add safe.directory $GITHUB_WORKSPACE
122+ git -c "http.https://github.com/.extraheader=" fetch --recurse-submodules=no "https://github.com/scala/scala3" && git reset --hard FETCH_HEAD || true
123+
124+ - name : Git Checkout
125+ uses : actions/checkout@v5
126+
127+ - name : Test
128+ run : sbt ";scala3-bootstrapped/compile; scala3-presentation-compiler/test; scala3-language-server/test"
129+ shell : cmd
130+
131+ - name : build binary
132+ run : sbt "dist-win-x86_64/Universal/stage" & bash -version
133+ shell : cmd
134+
135+ - name : cygwin tests
136+ run : ' "C:\Program Files\cygwin64\bin\bash" ./project/scripts/winCmdTests'
137+ shell : cmd
138+
139+ - name : msys tests
140+ run : ' "C:\Program Files\Git\bin\bash" ./project/scripts/winCmdTests'
141+ shell : cmd
142+
143+ - name : win tests
144+ run : ' ./project/scripts/winCmdTests.bat'
145+ shell : cmd
146+
54147 test_windows_full :
55148 runs-on : [self-hosted, Windows]
56149 if : " github.event_name == 'schedule' && github.repository == 'scala/scala3'
@@ -246,51 +339,6 @@ jobs:
246339 if : ${{ always() }}
247340 run : cat community-build/dotty-community-build-deps || true
248341
249- test_sbt :
250- runs-on : [self-hosted, Linux]
251- container :
252- image : lampepfl/dotty:2024-10-18
253- options : --cpu-shares 4096
254- volumes :
255- - ${{ github.workspace }}/../../cache/sbt:/root/.sbt
256- - ${{ github.workspace }}/../../cache/ivy:/root/.ivy2/cache
257- - ${{ github.workspace }}/../../cache/general:/root/.cache
258- if : " github.event_name == 'schedule' && github.repository == 'scala/scala3'
259- || github.event_name == 'push'
260- || (
261- github.event_name == 'pull_request'
262- && !contains(github.event.pull_request.body, '[skip ci]')
263- && !contains(github.event.pull_request.body, '[skip test_sbt]')
264- )
265- || (
266- github.event_name == 'workflow_dispatch'
267- && github.repository == 'scala/scala3'
268- )"
269-
270- steps :
271- - name : Set JDK 17 as default
272- run : echo "/usr/lib/jvm/java-17-openjdk-amd64/bin" >> $GITHUB_PATH
273-
274- - name : Reset existing repo
275- run : |
276- git config --global --add safe.directory $GITHUB_WORKSPACE
277- git -c "http.https://github.com/.extraheader=" fetch --recurse-submodules=no "https://github.com/scala/scala3" && git reset --hard FETCH_HEAD || true
278-
279- - name : Checkout cleanup script
280- uses : actions/checkout@v5
281-
282- - name : Cleanup
283- run : .github/workflows/cleanup.sh
284-
285- - name : Git Checkout
286- uses : actions/checkout@v5
287-
288- - name : Add SBT proxy repositories
289- run : cp -vf .github/workflows/repositories /root/.sbt/ ; true
290-
291- - name : Test sbt
292- run : ./project/scripts/sbt "sbt-test/scripted"
293-
294342 publish_release :
295343 permissions :
296344 contents : write # for GH CLI to create a release
@@ -302,7 +350,9 @@ jobs:
302350 - ${{ github.workspace }}/../../cache/sbt:/root/.sbt
303351 - ${{ github.workspace }}/../../cache/ivy:/root/.ivy2/cache
304352 - ${{ github.workspace }}/../../cache/general:/root/.cache
305- if : " github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags/')"
353+ needs : [test, community_build_a, community_build_b, community_build_c, build-sdk-package, build-msi-package]
354+ if : " github.event_name == 'push'
355+ && startsWith(github.event.ref, 'refs/tags/')"
306356
307357 env :
308358 RELEASEBUILD : yes
0 commit comments