diff options
author | Alon Zakai <alonzakai@gmail.com> | 2012-11-10 20:05:19 -0800 |
---|---|---|
committer | Alon Zakai <alonzakai@gmail.com> | 2012-11-10 20:05:19 -0800 |
commit | 795bcc6e76e59824d725acea1e9c2e1c553a6658 (patch) | |
tree | 00a2c232557e754c53d1ac7cf5f7b5fa14192e9e /tests | |
parent | 0a8dc20dfab06716146c8ecbda3518121940a737 (diff) |
clear cache and run sanity checks on version bumps, this will help with relooper updates etc.1.0.1
Diffstat (limited to 'tests')
-rwxr-xr-x | tests/runner.py | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/runner.py b/tests/runner.py index f965ffb1..413b27f9 100755 --- a/tests/runner.py +++ b/tests/runner.py @@ -10015,6 +10015,7 @@ fi self.assertContained(SANITY_MESSAGE, output) assert os.path.exists(SANITY_FILE) # EMCC should have checked sanity successfully assert mtime(SANITY_FILE) >= mtime(CONFIG_FILE) + assert open(SANITY_FILE).read() == EMSCRIPTEN_VERSION self.assertNotContained(SANITY_FAIL_MESSAGE, output) # emcc run again should not sanity check, because the sanity file is newer @@ -10022,6 +10023,16 @@ fi self.assertNotContained(SANITY_MESSAGE, output) self.assertNotContained(SANITY_FAIL_MESSAGE, output) + # correct sanity contents mean we need not check + open(SANITY_FILE, 'w').write(EMSCRIPTEN_VERSION) + output = self.check_working(EMCC) + self.assertNotContained(SANITY_MESSAGE, output) + + # incorrect sanity contents mean we *must* check + open(SANITY_FILE, 'w').write('wakawaka') + output = self.check_working(EMCC) + self.assertContained(SANITY_MESSAGE, output) + # but with EMCC_DEBUG=1 we should check assert not os.environ.get('EMCC_DEBUG'), 'do not run sanity checks in debug mode!' os.environ['EMCC_DEBUG'] = '1' |