Skip to content

Commit f9a0501

Browse files
committed
Travis: Move frozen tools check to the end
When the scripts for the old tools are modified (e.g. when a new target is added), the frozen tools check fails but we allow the change if it's really needed. By moving the frozen tools check to the end, Travis doesn't terminate early and the other tests get to run.
1 parent 77927d0 commit f9a0501

File tree

1 file changed

+32
-30
lines changed

1 file changed

+32
-30
lines changed

.travis.yml

Lines changed: 32 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -191,35 +191,6 @@ matrix:
191191
find -name "*.s" | tee BUILD/badasm |
192192
sed -e "s/^/Bad Assembler file name found: /" && [ ! -s BUILD/badasm ]
193193
194-
- <<: *docs-vm
195-
name: "Frozen tools check"
196-
env: NAME=frozen_tools_check
197-
script:
198-
# Reject any changes to tools that would require a re-release of the
199-
# tools for the online compiler.
200-
- >-
201-
frozen_files=`\
202-
git diff --name-only --diff-filter=d FETCH_HEAD..HEAD \
203-
| egrep \
204-
-e "^tools/build_api*" \
205-
-e "^tools/config*" \
206-
-e "^tools/export*" \
207-
-e "^tools/notifier*" \
208-
-e "^tools/paths*" \
209-
-e "^tools/resources*" \
210-
-e "^tools/targets*" \
211-
-e "^tools/toolchains*" \
212-
-e "^tools/utils*" \
213-
-e "^$"`
214-
if [ -z "$frozen_files" ]; then
215-
echo "Success!";
216-
else
217-
echo -e "Failure: Frozen files were modified\n$frozen_files";
218-
echo -e "Please see https://os.mbed.com/blog/entry/Introducing-the-new-Mbed-Tools/" \
219-
"\nfor why we've frozen the legacy tools.";
220-
false;
221-
fi
222-
223194
### Python Tests ###
224195
- &pytools-vm
225196
stage: "Pytest"
@@ -342,4 +313,35 @@ matrix:
342313
- echo ctest --build-and-test . build --build-generator Ninja --build-options -DBUILD_TESTING=ON -DCMAKE_BUILD_TYPE=Debug -DCOVERAGE=ON -DCMAKE_CXX_COMPILER=g++-7 -DCMAKE_C_COMPILER=gcc-7 --test-command ctest
343314
- ctest --build-and-test . build --build-generator Ninja --build-options -DBUILD_TESTING=ON -DCMAKE_BUILD_TYPE=Debug -DCOVERAGE=ON -DCMAKE_CXX_COMPILER=g++-7 -DCMAKE_C_COMPILER=gcc-7 --test-command ctest
344315
- gcovr --gcov-executable gcov-7 -r . ./build -s -e ".*\.h" --exclude-directories=$TRAVIS_BUILD_DIR/build/UNITTESTS --exclude-directories=$TRAVIS_BUILD_DIR/build/_deps
345-
- ccache -s
316+
- ccache -s
317+
318+
### Frozen tools check ###
319+
- &frozen-tools-vm
320+
stage: "Frozen tools check"
321+
name: "Frozen tools check"
322+
env: NAME=frozen_tools_check
323+
script:
324+
# Reject any changes to tools that would require a re-release of the
325+
# tools for the online compiler.
326+
- >-
327+
frozen_files=`\
328+
git diff --name-only --diff-filter=d FETCH_HEAD..HEAD \
329+
| egrep \
330+
-e "^tools/build_api*" \
331+
-e "^tools/config*" \
332+
-e "^tools/export*" \
333+
-e "^tools/notifier*" \
334+
-e "^tools/paths*" \
335+
-e "^tools/resources*" \
336+
-e "^tools/targets*" \
337+
-e "^tools/toolchains*" \
338+
-e "^tools/utils*" \
339+
-e "^$"`
340+
if [ -z "$frozen_files" ]; then
341+
echo "Success!";
342+
else
343+
echo -e "Failure: Frozen files were modified\n$frozen_files";
344+
echo -e "Please see https://os.mbed.com/blog/entry/Introducing-the-new-Mbed-Tools/" \
345+
"\nfor why we've frozen the legacy tools.";
346+
false;
347+
fi

0 commit comments

Comments
 (0)