You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
|`bazel test //rb/...`| Run unit, integration tests (Chrome) and lint |
218
+
|`bazel test //rb:lint`| Run RuboCop linter |
219
+
|`bazel test //rb/spec/...`| Run unit and integration tests (Chrome) |
220
+
|`bazel test --test_size_filters large //rb/...`| Run integration tests using (Chrome) |
221
+
|`bazel test //rb/spec/integration/...`| Run integration tests using (Chrome) |
222
+
|`bazel test //rb/spec/integration/... --define browser=firefox`| Run integration tests using (Firefox) |
223
+
|`bazel test //rb/spec/integration/... --define remote=true`| Run integration tests using (Chrome and Grid) |
224
+
|`bazel test //rb/spec/integration/... --define browser=firefox --define remote=true`| Run integration tests using (Firefox and Grid) |
225
+
|`bazel test --test_size_filters small //rb/...`| Run unit tests |
226
+
|`bazel test //rb/spec/unit/...`| Run unit tests |
224
227
225
228
Suffix `...` tells Bazel to run all the test targets. They are conveniently named by test file name with `_spec.rb` removed so you can run them individually:
If you want to debug code in tests, you can do it via [`debug`](https://github.com/ruby/debug) gem:
275
+
276
+
1. Add `binding.break` to the code where you want the debugger to start.
277
+
2. Run `bazel test --test_output streamed <test>`. Streaming output is not required, but will clearly say when debugger starts.
278
+
3. When debugger starts, run the following in a separate terminal to connect to debugger:
279
+
280
+
```sh
281
+
bazel-selenium/external/bundle/bin/rdbg -A
282
+
```
283
+
271
284
If you want to use RubyMine for development, a bit of extra configuration is necessary to let the IDE know about Bazel toolchain and artifacts:
272
285
273
286
1. Run `bazel build @bundle//:bundle //rb:selenium-devtools //rb:selenium-webdriver` before configuring IDE.
0 commit comments