find-cypress-specs 1.34.4 → 1.34.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -1,4 +1,4 @@
1
- # find-cypress-specs [![renovate-app badge][renovate-badge]][renovate-app] ![cypress version](https://img.shields.io/badge/cypress-12.14.0-brightgreen) [![ci](https://github.com/bahmutov/find-cypress-specs/actions/workflows/ci.yml/badge.svg?branch=main)](https://github.com/bahmutov/find-cypress-specs/actions/workflows/ci.yml)
1
+ # find-cypress-specs [![renovate-app badge][renovate-badge]][renovate-app] ![cypress version](https://img.shields.io/badge/cypress-12.17.1-brightgreen) [![ci](https://github.com/bahmutov/find-cypress-specs/actions/workflows/ci.yml/badge.svg?branch=main)](https://github.com/bahmutov/find-cypress-specs/actions/workflows/ci.yml)
2
2
 
3
3
  > Find Cypress spec files using the config settings
4
4
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "find-cypress-specs",
3
- "version": "1.34.4",
3
+ "version": "1.34.6",
4
4
  "description": "Find Cypress spec files using the config settings",
5
5
  "main": "src",
6
6
  "files": [
@@ -51,12 +51,12 @@
51
51
  "homepage": "https://github.com/bahmutov/find-cypress-specs#readme",
52
52
  "devDependencies": {
53
53
  "ava": "^4.0.0",
54
- "cypress": "12.14.0",
54
+ "cypress": "12.17.1",
55
55
  "dependency-version-badge": "^1.11.0",
56
56
  "execa-wrap": "^1.4.0",
57
57
  "prettier": "^2.5.1",
58
58
  "really-need": "^1.9.2",
59
- "semantic-release": "21.0.3",
59
+ "semantic-release": "21.0.7",
60
60
  "sinon": "^13.0.1",
61
61
  "typescript": "^4.6.3"
62
62
  },
@@ -65,8 +65,8 @@
65
65
  "arg": "^5.0.1",
66
66
  "console.table": "^0.10.0",
67
67
  "debug": "^4.3.3",
68
- "find-test-names": "1.28.12",
69
- "globby": "^11.0.4",
68
+ "find-test-names": "1.28.13",
69
+ "globby": "^11.1.0",
70
70
  "minimatch": "^3.0.4",
71
71
  "pluralize": "^8.0.0",
72
72
  "require-and-forget": "^1.0.1",
package/src/index.js CHANGED
@@ -115,6 +115,7 @@ function findCypressSpecsV9(opts = {}) {
115
115
  }
116
116
 
117
117
  function findCypressSpecsV10(opts = {}, type = 'e2e') {
118
+ debug('findCypressSpecsV10')
118
119
  if (type !== 'e2e' && type !== 'component') {
119
120
  throw new Error(`Unknown spec type ${type}`)
120
121
  }
@@ -146,11 +147,19 @@ function findCypressSpecsV10(opts = {}, type = 'e2e') {
146
147
 
147
148
  debug('options v10 %o', options)
148
149
 
149
- /** @type string[] */
150
- const files = globby.sync(options.specPattern, {
150
+ const ignore = Array.isArray(options.excludeSpecPattern)
151
+ ? options.excludeSpecPattern
152
+ : options.excludeSpecPattern
153
+ ? [options.excludeSpecPattern]
154
+ : []
155
+ const globbyOptions = {
151
156
  sort: true,
152
- ignore: options.excludeSpecPattern,
153
- })
157
+ ignore,
158
+ }
159
+ debug('globby options %s %o', options.specPattern, globbyOptions)
160
+
161
+ /** @type string[] */
162
+ const files = globby.sync(options.specPattern, globbyOptions)
154
163
  debug('found %d file(s) %o', files.length, files)
155
164
 
156
165
  // go through the files again and eliminate files that match