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

Fix name collisions with test functions and intrinsics #2123

Merged
merged 1 commit into from
May 4, 2020

Conversation

alexcrichton
Copy link
Contributor

There was an unfortunate collision with how test symbols were named and
the various bindings functions exported by wasm-bindgen. This commit
fixes these issues by using a separate prefix for #[wasm_bindgen_test]
than other #[wasm_bindgen] functions which should avoid the name
clash.

Closes #2121

There was an unfortunate collision with how test symbols were named and
the various bindings functions exported by wasm-bindgen. This commit
fixes these issues by using a separate prefix for `#[wasm_bindgen_test]`
than other `#[wasm_bindgen]` functions which should avoid the name
clash.

Closes rustwasm#2121
@alexcrichton alexcrichton merged commit dc54c0f into rustwasm:master May 4, 2020
@alexcrichton alexcrichton deleted the fix-collision branch May 4, 2020 21:20
quodlibetor added a commit to schrieveslaach/chrono that referenced this pull request Jul 5, 2020
wasm-bindgen-test and wasm-bindgen need to be different versions (0.3 and 0.2,
respectively), otherwise no tests are found([1], [2]);

This also fixes the test to and ci runner to just test in the current env/tz,
thereby requiring that js_sys returns the same timezone as the host system
thinks it is, but not otherwise trying to set the TZ.

[1]: https://users.rust-lang.org/t/wasm-bindgen-test-and-no-tests-to-run/43444
[2]: rustwasm/wasm-bindgen#2123
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Structs whose name begins with "Test" cause run-time failures in wasm-bindgen-test tests
1 participant