Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Come up with a test case for the sourcemap generation code (WASM::map_v3) #2

Open
mtolmacs opened this issue Apr 19, 2023 · 0 comments
Labels
test Testing related issue

Comments

@mtolmacs
Copy link
Owner

Background

Testing the valid sourcemap generation capabilities of the library can't be easily accomplished. Since this library translates DWARF code, in order to test it we need to inspect both the sourcemap and the DWARF code, which basically means a complete reimplementation of this lib (which in turn is quite pointless).

The obvious solution would be to run another tool on the same WASM file and compare the results. For this purpose the original inspiration, Emscripten's wasm_sourcemap.py can be run via an external python interpreter in the test. The downside is that it requires the test runner to have python installed.

Success

Total code coverage on the sourcemap generation code in the lib (i.e. WASM::load(), WASM::map_v3(), WASM::generate(),WASM::encode_vlq)

@mtolmacs mtolmacs added the test Testing related issue label Apr 19, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
test Testing related issue
Projects
None yet
Development

No branches or pull requests

1 participant