mirror of
https://github.com/yewstack/yew.git
synced 2025-12-08 21:26:25 +00:00
Contributor testing docs improvement (#969)
* initial * Update CONTRIBUTING.md Co-authored-by: Justin Starry <justin.m.starry@gmail.com>
This commit is contained in:
parent
6a759329d1
commit
2a7d7acb43
@ -27,7 +27,9 @@ cargo build --target wasm32-unknown-unknown
|
|||||||
```
|
```
|
||||||
|
|
||||||
#### Test
|
#### Test
|
||||||
For the tests to work one have to ensure that `wasm-bindgen-cli` is installed.
|
|
||||||
|
##### Web Tests
|
||||||
|
First, ensure that `wasm-bindgen-cli` is installed.
|
||||||
[Instructions](https://rustwasm.github.io/docs/wasm-bindgen/wasm-bindgen-test/usage.html#install-the-test-runner)
|
[Instructions](https://rustwasm.github.io/docs/wasm-bindgen/wasm-bindgen-test/usage.html#install-the-test-runner)
|
||||||
|
|
||||||
Additionally a webdriver must be installed locally and configured to be on the
|
Additionally a webdriver must be installed locally and configured to be on the
|
||||||
@ -38,6 +40,13 @@ although more driver support may be added! You can download these at:
|
|||||||
* chromedriver - http://chromedriver.chromium.org/downloads
|
* chromedriver - http://chromedriver.chromium.org/downloads
|
||||||
* safaridriver - should be preinstalled on OSX
|
* safaridriver - should be preinstalled on OSX
|
||||||
|
|
||||||
|
##### Macro Tests
|
||||||
|
When adding or updating tests, please make sure you have updated the appropriate `stderr` file, which you can find [here](https://github.com/yewstack/yew/tree/master/tests/macro) for the `html!` macro. These files ensure that macro compilation errors are correct and easy to understand.
|
||||||
|
|
||||||
|
To update or generate a new `stderr` file you can run `TRYBUILD=overwrite cargo test --test macro_test` or `TRYBUILD=overwrite cargo test --test derive_props_test`.
|
||||||
|
|
||||||
|
##### Running Tests
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
./ci/run_tests.sh
|
./ci/run_tests.sh
|
||||||
```
|
```
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user