Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2)

Side by Side Diff: tool/test.sh

Issue 1056613002: reduce diff churn due to server_mode test (Closed) Base URL: git@github.com:dart-lang/dev_compiler.git@master
Patch Set: Created 5 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« test/codegen_test.dart ('K') | « test/codegen_test.dart ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/bin/bash 1 #!/bin/bash
2 set -e # bail on error 2 set -e # bail on error
3 3
4 function fail { 4 function fail {
5 echo -e "Some tests failed" 5 echo -e "Some tests failed"
6 return 1 6 return 1
7 } 7 }
8 8
9 # Arguments passed to the diff tool. We exclude: 9 # Arguments passed to the diff tool. We exclude:
10 # - *.map files so they aren't compared, as the diff is not human readable. 10 # - *.map files so they aren't compared, as the diff is not human readable.
(...skipping 24 matching lines...) Expand all
35 # this will cause us to generate files that are not part of the baseline 35 # this will cause us to generate files that are not part of the baseline
36 # TODO(jmesserly): we should move diff into Dart code, so we don't need to 36 # TODO(jmesserly): we should move diff into Dart code, so we don't need to
37 # worry about this. Also if we're in code coverage mode, we should avoid running 37 # worry about this. Also if we're in code coverage mode, we should avoid running
38 # all_tests twice. Finally self_host_test is not currently being tracked by 38 # all_tests twice. Finally self_host_test is not currently being tracked by
39 # code coverage. 39 # code coverage.
40 unset COVERALLS_TOKEN 40 unset COVERALLS_TOKEN
41 dart -c test/all_tests.dart || fail 41 dart -c test/all_tests.dart || fail
42 42
43 # validate codegen_test output 43 # validate codegen_test output
44 pushd test/codegen/ &> /dev/null 44 pushd test/codegen/ &> /dev/null
45 rm -r actual/dev_compiler/ actual/server_mode/dev_compiler/ \ 45 rm -r actual/dev_compiler/ actual/sunflower/dev_compiler
46 actual/sunflower/dev_compiler
47 diff $DIFF_ARGS > /dev/null || show_diff 46 diff $DIFF_ARGS > /dev/null || show_diff
48 popd &> /dev/null 47 popd &> /dev/null
49 48
50 # validate dart_codegen_test output 49 # validate dart_codegen_test output
51 pushd test/dart_codegen/ &> /dev/null 50 pushd test/dart_codegen/ &> /dev/null
52 diff $DIFF_ARGS > /dev/null || show_diff 51 diff $DIFF_ARGS > /dev/null || show_diff
53 popd &> /dev/null 52 popd &> /dev/null
54 53
55 # run self host and analyzer after other tests, because they're ~seconds to run. 54 # run self host and analyzer after other tests, because they're ~seconds to run.
56 dart -c test/checker/self_host_test.dart || fail 55 dart -c test/checker/self_host_test.dart || fail
(...skipping 18 matching lines...) Expand all
75 # The formatter ignores: 74 # The formatter ignores:
76 # * local files that have never been added to git, 75 # * local files that have never been added to git,
77 # * subdirectories of test/ and tool/, unless explicitly added. Those dirs 76 # * subdirectories of test/ and tool/, unless explicitly added. Those dirs
78 # contain a lot of generated or external source we should not reformat. 77 # contain a lot of generated or external source we should not reformat.
79 (files=`git ls-files 'bin/*.dart' 'lib/*.dart' test/*.dart test/checker/*.dart \ 78 (files=`git ls-files 'bin/*.dart' 'lib/*.dart' test/*.dart test/checker/*.dart \
80 tool/*.dart | grep -v lib/src/js/`; git status -s $files | grep -q . \ 79 tool/*.dart | grep -v lib/src/js/`; git status -s $files | grep -q . \
81 && echo "Did not run the formatter, please commit edited files first." \ 80 && echo "Did not run the formatter, please commit edited files first." \
82 || (echo "Running dart formatter" ; pub run dart_style:format -w $files)) 81 || (echo "Running dart formatter" ; pub run dart_style:format -w $files))
83 82
84 echo -e "All tests pass" 83 echo -e "All tests pass"
OLDNEW
« test/codegen_test.dart ('K') | « test/codegen_test.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698