find-cypress-specs 1.29.2 → 1.29.4
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/package.json +1 -1
- package/src/index.js +11 -9
package/package.json
CHANGED
package/src/index.js
CHANGED
|
@@ -197,6 +197,7 @@ function getSpecs(options, type) {
|
|
|
197
197
|
if ('testingType' in options) {
|
|
198
198
|
type = options.testingType
|
|
199
199
|
options = {
|
|
200
|
+
version: options.version,
|
|
200
201
|
[type]: {
|
|
201
202
|
specPattern: options.specPattern,
|
|
202
203
|
excludeSpecPattern: options.excludeSpecPattern,
|
|
@@ -209,20 +210,21 @@ function getSpecs(options, type) {
|
|
|
209
210
|
}
|
|
210
211
|
|
|
211
212
|
function findCypressSpecs(options, type = 'e2e') {
|
|
212
|
-
debug(
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
)
|
|
213
|
+
debug('finding specs of type %s', type)
|
|
214
|
+
if (options.version) {
|
|
215
|
+
debug('Cypress version %s', options.version)
|
|
216
|
+
}
|
|
217
217
|
|
|
218
|
-
|
|
218
|
+
let cyVersion = options.version
|
|
219
|
+
if (typeof cyVersion !== 'string') {
|
|
219
220
|
if ('integrationFolder' in options) {
|
|
220
|
-
|
|
221
|
+
cyVersion = '9.0.0'
|
|
221
222
|
} else {
|
|
222
|
-
|
|
223
|
+
cyVersion = '10.0.0'
|
|
223
224
|
}
|
|
224
225
|
}
|
|
225
|
-
const [major] =
|
|
226
|
+
const [major] = cyVersion.split('.').map(Number)
|
|
227
|
+
debug('treating options as Cypress version %d', major)
|
|
226
228
|
|
|
227
229
|
if (type === 'e2e') {
|
|
228
230
|
if (major >= 10) {
|