Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Custom Cypress tests #237

Closed
wants to merge 11 commits into from
3 changes: 1 addition & 2 deletions cypress.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,7 @@ export default defineConfig({
viewportWidth: 1000,
viewportHeight: 600,
e2e: {
supportFile: "cypress/support/index.js",
specPattern: "cypress/integration/**/*.test.{js,jsx,ts,tsx}",
specPattern: "cypress/e2e/**/*.test.{js,jsx,ts,tsx}",
setupNodeEvents(on, config) {
return require("cypress/plugins/index.js")(on, config);
},
Expand Down
1 change: 1 addition & 0 deletions faststore.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ module.exports = {
experimental: {
nodeVersion: 18,
cypressVersion: 12,
enableCypressExtension: true,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are we going to enable it as default? I think we shouldn't, the user should enable it when needed, WTDY?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yep, we won't change that, it was just for testing purposes 🤝

},
account: "storeframework",
vtexHeadlessCms: {
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
},
"devDependencies": {
"@cypress/code-coverage": "^3.12.1",
"@faststore/cli": "2.2.5",
"@faststore/cli": "https://pkg.csb.dev/vtex/faststore/commit/4768c724/@faststore/cli",
"@faststore/lighthouse": "^2.2.0",
"@lhci/cli": "^0.9.0",
"@testing-library/cypress": "^10.0.1",
Expand Down
17 changes: 14 additions & 3 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -968,10 +968,21 @@
p-limit "^3.1.0"
sanitize-html "^2.11.0"

"@faststore/cli@2.2.5":
"@faststore/cli@https://pkg.csb.dev/vtex/faststore/commit/4768c724/@faststore/cli":
version "2.2.5"
resolved "https://registry.yarnpkg.com/@faststore/cli/-/cli-2.2.5.tgz#66e325fad123f8910ab49fd58329391c8c46fe0f"
integrity sha512-1KO81wi6nB7nyHsjRn5mLBRPFcg0FecXbq1NJRqxdXYmWkDTgT6lf5EeRqoNPuRuvbn+ZtT/vo/ivVncAb7Xgg==
resolved "https://pkg.csb.dev/vtex/faststore/commit/4768c724/@faststore/cli#4395efcbce3cadc0a07223fe3fb3cdcd40ffd121"
dependencies:
"@oclif/core" "^1.16.4"
"@oclif/plugin-help" "^5"
"@oclif/plugin-not-found" "^2.3.3"
chalk "~4.1.2"
chokidar "^3.5.3"
fs-extra "^10.1.0"
path "^0.12.7"

"@faststore/cli@https://pkg.csb.dev/vtex/faststore/commit/be4de8a9/@faststore/cli":
version "2.2.5"
resolved "https://pkg.csb.dev/vtex/faststore/commit/be4de8a9/@faststore/cli#2e5ad7a4766f3f0e2c2b4a44a7f6beaf10b551d4"
dependencies:
"@oclif/core" "^1.16.4"
"@oclif/plugin-help" "^5"
Expand Down