diff options
-rwxr-xr-x | emcc | 2 | ||||
-rwxr-xr-x | tests/runner.py | 12 |
2 files changed, 13 insertions, 1 deletions
@@ -994,7 +994,7 @@ try: for change in settings_changes: key, value = change.split('=') if value[0] == '@': - value = '"' + value + '"' + value = '"@' + os.path.abspath(value[1:]) + '"' exec('shared.Settings.' + key + ' = ' + value) # Apply effects from settings diff --git a/tests/runner.py b/tests/runner.py index 1b5666c3..a6b90f8d 100755 --- a/tests/runner.py +++ b/tests/runner.py @@ -8605,6 +8605,18 @@ def process(filename): open('dead_funcs', 'w').write(pgo_output[pgo_output.find('['):-1]) self.emcc_args += ['-s', 'DEAD_FUNCTIONS=@' + self.in_dir('dead_funcs')] self.do_run(src, output) + self.emcc_args.pop() + self.emcc_args.pop() + shutil.move(self.in_dir('src.cpp.o.js'), self.in_dir('pgoed2.js')) + assert open('pgoed.js').read() == open('pgoed2.js').read() + + # with relative response in settings element itself + + open('dead_funcs', 'w').write(pgo_output[pgo_output.find('['):-1]) + self.emcc_args += ['-s', 'DEAD_FUNCTIONS=@dead_funcs'] + self.do_run(src, output) + self.emcc_args.pop() + self.emcc_args.pop() shutil.move(self.in_dir('src.cpp.o.js'), self.in_dir('pgoed2.js')) assert open('pgoed.js').read() == open('pgoed2.js').read() |