adorable-action-72456
06/28/2022, 6:12 PMadorable-action-72456
06/28/2022, 6:13 PMadorable-action-72456
06/28/2022, 6:13 PMfew-ocean-46787
06/28/2022, 8:23 PMrich-pharmacist-74804
06/29/2022, 7:01 AMrich-pharmacist-74804
06/29/2022, 7:38 AMfull-wolf-13612
06/29/2022, 1:47 PMlate-planet-4481
06/29/2022, 1:50 PMnpm install
or npm update
.
Also, if you are doing anything unconventional in your tests (writing to console with every step) maybe try eliminating that stuff to see if it changes anything.
You might also tinker with the soon-to-be-deprecated nodeVersion
config option.
https://docs.cypress.io/guides/references/configuration#Node-versionmagnificent-finland-58048
06/29/2022, 3:17 PMproud-cpu-57518
06/29/2022, 11:41 PMmagnificent-finland-58048
06/30/2022, 9:47 AMbillowy-petabyte-20119
06/30/2022, 7:36 PMbrainy-lamp-73353
07/01/2022, 9:58 AMfresh-doctor-14925
07/01/2022, 10:08 AMfresh-doctor-14925
07/03/2022, 12:31 PMadorable-action-72456
07/03/2022, 12:43 PMfresh-doctor-14925
07/03/2022, 3:16 PM?????
isn't the right way to approach this. Especially when no one is obliged to provide you with an answer
Have you checked what comes up when you do Cypress.env("specPattern")
? That will give you a definitive answer as to whether your environment variable is overriding what's in your config file. If it's showing the value set in your config file, rather than your environment variable, then that sounds like a bug. You can raise bugs here: https://github.com/cypress-io/cypress/issuesadorable-stone-42197
07/04/2022, 8:18 AMimportant-diamond-61614
07/05/2022, 9:38 AMcypress open --browser chrome --e2e
or cypress run chrome --e2e
runs without issue, and finds all the relevant spec files. But when I use a command which runs a js file: CONFIG_FILE=qa1.mt1_all MARKET=all DEVICE=desktop node index.js
It cannot find the spec files, and returns the error:
Can't run because no spec files were found.
We searched for specs matching this glob pattern:
> /Users/oiuasofd/code/oiuasodf/node/repo-name/cypress/e2e/**/*.cy.{js,jsx,ts,tsx}
The contents of index.js
const cypress = require('cypress');
const { v4: uuidv4 } = require('uuid');
cypress
.run({
browser: 'chrome',
headless: true,
record: true,
parallel: true,
ciBuildId: process.env.BUILD_ID || uuidv4(),
key: 'randomly-generated-string', // This is a unique value for running parallel tests
config: {
env: {
configFile: process.env.CONFIG_FILE || '',
device: process.env.DEVICE,
market: process.env.MARKET,
},
},
})
.catch(() => {
process.exit(1);
});
magnificent-finland-58048
07/05/2022, 11:14 AMqa1.mt1_all
? What happens if you append .js / .ts to it?important-diamond-61614
07/05/2022, 11:54 AMmagnificent-finland-58048
07/05/2022, 12:16 PMmagnificent-finland-58048
07/05/2022, 12:16 PMimportant-diamond-61614
07/05/2022, 12:27 PMcypress open --browser chrome --e2e
or cypress run chrome --e2e
important-diamond-61614
07/05/2022, 12:59 PMgorgeous-knife-39039
07/05/2022, 1:04 PMastonishing-electrician-44897
07/05/2022, 2:40 PMcypress.config.ts
to see whats going wrong.magnificent-telephone-56514
07/06/2022, 8:51 AM_spec.js
to cy.js
but I just get this when running from command line.
Can't run because no spec files were found.
We searched for specs matching this glob pattern:
Everything works fine when using the runnerbulky-engine-91129
07/06/2022, 3:19 PMadorable-smartphone-87280
07/06/2022, 3:35 PM/cypress/e2e/
not /cypress/integration/