|
11 | 11 | import subprocess
|
12 | 12 | import time
|
13 | 13 | import unittest
|
14 |
| -import webbrowser |
15 | 14 | import zlib
|
16 | 15 | from functools import wraps
|
17 | 16 | from http.server import BaseHTTPRequestHandler, HTTPServer
|
@@ -280,44 +279,6 @@ def test_sdl1(self):
|
280 | 279 | def test_sdl1_es6(self):
|
281 | 280 | self.reftest('hello_world_sdl.c', 'htmltest.png', cflags=['-sUSE_SDL', '-lGL', '-sEXPORT_ES6'])
|
282 | 281 |
|
283 |
| - # Deliberately named as test_zzz_* to make this test the last one |
284 |
| - # as this test may take the focus away from the main test window |
285 |
| - # by opening a new window and possibly not closing it. |
286 |
| - def test_zzz_html_source_map(self): |
287 |
| - # browsers will try to 'guess' the corresponding original line if a |
288 |
| - # generated line is unmapped, so if we want to make sure that our |
289 |
| - # numbering is correct, we need to provide a couple of 'possible wrong |
290 |
| - # answers'. thus, we add some printf calls so that the cpp file gets |
291 |
| - # multiple mapped lines. in other words, if the program consists of a |
292 |
| - # single 'throw' statement, browsers may just map any thrown exception to |
293 |
| - # that line, because it will be the only mapped line. |
294 |
| - create_file('src.cpp', r''' |
295 |
| - #include <cstdio> |
296 |
| -
|
297 |
| - int main() { |
298 |
| - printf("Starting test\n"); |
299 |
| - try { |
300 |
| - throw 42; // line 8 |
301 |
| - } catch (int e) { } |
302 |
| - printf("done\n"); |
303 |
| - return 0; |
304 |
| - } |
305 |
| - ''') |
306 |
| - # use relative paths when calling emcc, because file:// URIs can only load |
307 |
| - # sourceContent when the maps are relative paths |
308 |
| - self.compile_btest('src.cpp', ['-o', 'src.html', '-gsource-map']) |
309 |
| - self.assertExists('src.html') |
310 |
| - self.assertExists('src.wasm.map') |
311 |
| - if not has_browser(): |
312 |
| - self.skipTest('need a browser') |
313 |
| - webbrowser.open_new('file://src.html') |
314 |
| - print(''' |
315 |
| -If manually bisecting: |
316 |
| - Check that you see src.cpp among the page sources. |
317 |
| - Even better, add a breakpoint, e.g. on the printf, then reload, then step |
318 |
| - through and see the print (best to run with --save-dir for the reload). |
319 |
| -''') |
320 |
| - |
321 | 282 | def test_emscripten_log(self):
|
322 | 283 | self.btest_exit('test_emscripten_log.cpp', cflags=['-Wno-deprecated-pragma', '-gsource-map'])
|
323 | 284 |
|
|
0 commit comments