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

I can run the test and record it but it is not uploading to dashboard #3467

Closed
MarcoAmaralQA opened this issue Feb 14, 2019 · 3 comments
Closed

Comments

@MarcoAmaralQA
Copy link

MarcoAmaralQA commented Feb 14, 2019

Hey guys,

I installed Cypress via NPM on windows 10 and I am able to run Cypress and the Test runner but when I run the command > npm run cy:run --record --key XXX --spec 'cypress\integration\POWr-Tests\log-in-test.js' to record the test it does not populate my dashboard or appears on Cypress > Runs Tab.

I got 2 issues that I do not know how to address it.

1 - Issue > It does not run the only test on the file I selected it runs the test on all files inside Integrations folder the examples files and my tests which is in a subfolder inside Integrations folder.

I ran this command > npm run cy:run --record --key XXX --spec 'cypress\integration\POWr-Tests\log-in-test.js'

2 - Issue > After the test runs I get the success message, however, no files are uploaded to the dashboard or any data about this run is on and the Runs Tab on Cypress. This tab is empty as well as the dashboard.

This is the cy:run result > https://www.screencast.com/t/2urDhnceTWUK
This what I see on Runs tab after executed the command cy:run > https://www.screencast.com/t/iOliOq7hH
My dashboard after running cy:run > https://www.screencast.com/t/g7mcohuJ

I installed Cypress version 3.1.5

I can see the video file created on the videos folder after I run the script.

Here are the settings:

{
animationDistanceThreshold: 5,
baseUrl: null,
blacklistHosts: null,
chromeWebSecurity: false,
defaultCommandTimeout: 4000,
env: {},
execTimeout: 1000000,
fileServerFolder: '',
fixturesFolder: 'cypress/fixtures',
hosts: null,
integrationFolder: 'cypress/integration',
modifyObstructiveCode: true,
numTestsKeptInMemory: 50,
pageLoadTimeout: 100000,
pluginsFile: 'cypress/plugins',
port: null,
reporter: 'spec',
reporterOptions: null,
requestTimeout: 5000,
responseTimeout: 30000,
screenshotsFolder: 'cypress/screenshots',
supportFile: 'cypress/support',
taskTimeout: 60000,
testFiles: '**/*.*',
trashAssetsBeforeRuns: true,
userAgent: null,
video: true,
videoCompression: 32,
videoUploadOnPasses: true,
videosFolder: 'cypress/videos',
viewportHeight: 660,
viewportWidth: 1000,
waitForAnimations: true,
watchForFileChanges: true}

Can anyone help me?

Cheers.

@MarcoAmaralQA MarcoAmaralQA changed the title I can run the test and record it but it is no uploading to dashboard I can run the test and record it but it is not uploading to dashboard Feb 14, 2019
@bahmutov
Copy link
Contributor

@MarcoAmaralQA can you check please, are you running exactly the command as you have written it?

npm run cy:run --record --key XXX

When you run NPM scripts you HAVE to separate arguments to the tool with --, so the command has to be

npm run cy:run -- --record --key XXX

@MarcoAmaralQA
Copy link
Author

MarcoAmaralQA commented Feb 14, 2019

@bahmutov,

If I run > npm run cy:run --record --key xxx --spec 'path\to\file' it runs but it does not upload the file after it finishes.

If I run > .\node_modules\.bin\cypress run --record --key xxx --spec 'path\to\file' it runs and uploads the file after it finishes.

I ran > npm run cy:run -- --record --key XXX --spec 'path\to\file' and it worked.

Cheers.

@bahmutov
Copy link
Contributor

so when running npm run cy:run --record --key xxx it was "swallowing" --record and passing other flags, so Cypress ran everything but without recording. We are thinking how to solve it in user-friendly manner in proposal #3470 but this issue is resolved 🎉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants