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

"npm run test:e2e" exits to command prompt #5710

Closed
ZwapKillrath opened this issue Nov 15, 2019 · 8 comments
Closed

"npm run test:e2e" exits to command prompt #5710

ZwapKillrath opened this issue Nov 15, 2019 · 8 comments
Labels
type: duplicate This issue or pull request already exists

Comments

@ZwapKillrath
Copy link

ZwapKillrath commented Nov 15, 2019

Current behavior:

Brand new Vue project (vue create), install Vuetify (vue add Vuetify)

npm install cypress --save-dev

package.json:

{
  "name": "democypress",
  "version": "0.1.0",
  "private": true,
  "scripts": {
    "serve": "vue-cli-service serve",
    "build": "vue-cli-service build",
    "lint": "vue-cli-service lint",
    "test:e2e": "vue-cli-service test:e2e"
  },
  "dependencies": {
    "@mdi/font": "^4.5.95",
    "core-js": "^3.3.2",
    "material-design-icons-iconfont": "^5.0.1",
    "register-service-worker": "^1.6.2",
    "roboto-fontface": "^0.10.0",
    "vue": "^2.6.10",
    "vue-class-component": "^7.0.2",
    "vue-property-decorator": "^8.3.0",
    "vue-router": "^3.1.3",
    "vuetify": "^2.1.0"
  },
  "devDependencies": {
    "@types/node": "^12.12.7",
    "@typescript-eslint/eslint-plugin": "^2.7.0",
    "@typescript-eslint/parser": "^2.7.0",
    "@vue/cli-plugin-babel": "^4.0.0",
    "@vue/cli-plugin-e2e-cypress": "^4.0.0",
    "@vue/cli-plugin-pwa": "^4.0.0",
    "@vue/cli-plugin-typescript": "^4.0.0",
    "@vue/cli-service": "^4.0.0",
    "cypress": "^3.6.1",
    "eslint": "^6.6.0",
    "eslint-config-google": "^0.14.0",
    "eslint-plugin-vue": "^6.0.1",
    "sass": "^1.19.0",
    "sass-loader": "^8.0.0",
    "stylus": "^0.54.7",
    "stylus-loader": "^3.0.2",
    "typescript": "^3.7.2",
    "vue-cli-plugin-vuetify": "^2.0.2",
    "vue-template-compiler": "^2.6.10",
    "vuetify-loader": "^1.3.0"
  }
}

"npm run test:e2e" just exits to the command line with no test runner shown.

Desired behavior:

Want Cypress to show the test runner and ready to manually run tests.

Steps to reproduce: (app code and test code)

New vue project, add Vuetify and Cypress
npm run test:e2e
(all executed from the project folder)

PS: The test runner opens with "npx cypress open" but not able to hit the pages with cy.visit() - results in "404 page not found" when test scripts are executed.

Versions

Cypress 3.6.1
Windows 10 64 bit
Chrome etc.

@trajano
Copy link

trajano commented Nov 16, 2019

I am hitting the same issue though I didn't have Chrome installed. However, installing Chrome didn't help either.

@trajano
Copy link

trajano commented Nov 16, 2019

Also running in --headless mode fails

@trajano
Copy link

trajano commented Nov 16, 2019

I got it working by downgrading Cypress. The last known version that worked for my project was 3.4.1.

https://github.com/trajano/vue-cordova/blob/v0.1.2/package-lock.json#L3443

So I downgraded npm install --save-dev [email protected]

Upgrading to cypress 3.5 causes it to fail so it appears to be introduced in 3.5

@ZwapKillrath
Copy link
Author

I got it working by downgrading Cypress. The last known version that worked for my project was 3.4.1.

https://github.com/trajano/vue-cordova/blob/v0.1.2/package-lock.json#L3443

So I downgraded npm install --save-dev [email protected]

Upgrading to cypress 3.5 causes it to fail so it appears to be introduced in 3.5

Yup. Exactly the same here. We are running 3.4.1 at the moment but would like to upgrade to 3.6.
@jennifer-shehane Do you have a resolution for this?

@trajano
Copy link

trajano commented Nov 19, 2019

Not only that I have to downgrade to 3.4.1 of Cypress, but I can't upgrade to Node 12.13 which is LTS. I think it may work with 12.11

@ZwapKillrath
Copy link
Author

Same problem in 3.7.0

@jennifer-shehane
Copy link
Member

From #5843

image

Cypress test runner never starts - just exits to cmd prompt when doing "npm run test:e2e".
(set DEBUG=cypress:* used here)

@jennifer-shehane
Copy link
Member

This is a bit tricky to detect, but this is a duplicate of #5466 - this is isolated to Windows when passing an argument containing a url (such as baseUrl=https://localhost:3000, which is what the vue cli does by default.

We're working on deciding how to move forward with fixing.

@jennifer-shehane jennifer-shehane added the type: duplicate This issue or pull request already exists label Dec 3, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: duplicate This issue or pull request already exists
Projects
None yet
Development

No branches or pull requests

3 participants