fix browser.test_uuid to use the temp test dir normally
This commit is contained in:
Родитель
e6811d0e2d
Коммит
a7e73f6479
|
@ -1856,15 +1856,15 @@ void *getBindBuffer() {
|
|||
|
||||
# First run tests in Node and/or SPIDERMONKEY using run_js. Use closure compiler so we can check that
|
||||
# require('crypto').randomBytes and window.crypto.getRandomValues doesn't get minified out.
|
||||
Popen([PYTHON, EMCC, '-O2', '--closure', '1', path_from_root('tests', 'uuid', 'test.c'), '-o', path_from_root('tests', 'uuid', 'test.js')], stdout=PIPE, stderr=PIPE).communicate()
|
||||
Popen([PYTHON, EMCC, '-O2', '--closure', '1', path_from_root('tests', 'uuid', 'test.c'), '-o', 'test.js'], stdout=PIPE, stderr=PIPE).communicate()
|
||||
|
||||
test_js_closure = open(path_from_root('tests', 'uuid', 'test.js')).read()
|
||||
test_js_closure = open('test.js').read()
|
||||
|
||||
# Check that test.js compiled with --closure 1 contains ").randomBytes" and "window.crypto.getRandomValues"
|
||||
assert ").randomBytes" in test_js_closure
|
||||
assert "window.crypto.getRandomValues" in test_js_closure
|
||||
|
||||
out = run_js(path_from_root('tests', 'uuid', 'test.js'), full_output=True)
|
||||
out = run_js('test.js', full_output=True)
|
||||
print out
|
||||
|
||||
# Tidy up files that might have been created by this test.
|
||||
|
|
Загрузка…
Ссылка в новой задаче