cypress-grep
Advanced tools
Comparing version 2.0.0 to 2.1.0
{ | ||
"name": "cypress-grep", | ||
"version": "2.0.0", | ||
"version": "2.1.0", | ||
"description": "Filter tests using substring", | ||
@@ -9,2 +9,3 @@ "main": "src/support", | ||
], | ||
"types": "src/index.d.ts", | ||
"scripts": { | ||
@@ -11,0 +12,0 @@ "test": "cypress run --config testFiles='**/unit.js'", |
@@ -105,2 +105,13 @@ # cypress-grep | ||
You can select tests to run or skip using tags by passing `--env grepTags=...` value. | ||
``` | ||
# enable the tests with tag "one" or "two" | ||
--env grepTags="one two" | ||
# enable the tests with both tags "one" and "two" | ||
--env grepTags="one+two" | ||
# enable the tests with "hello" in the title and tag "smoke" | ||
--env grep=hello,grepTags=smoke | ||
``` | ||
### Tags in the test config object | ||
@@ -133,2 +144,9 @@ | ||
This package comes with [src/index.d.ts](./src/index.d.ts) definition file that adds the property `tags` to the Cypress test overrides interface. Include this file in your specs or TS config settings. For example, you can load it using a reference comment | ||
```js | ||
// cypress/integration/my-spec.js | ||
/// <reference types="cypress-grep" /> | ||
``` | ||
## Test suites | ||
@@ -135,0 +153,0 @@ |
17666
6
229
323