cypress-io / cypress-chrome-recorder

Export Cypress Tests from Google Chrome DevTools' Recorder
MIT License
226 stars 18 forks source link

Issue writing the output to cypress/integration #27

Closed Puneet-humm closed 2 years ago

Puneet-humm commented 2 years ago

I have created a login.json file through chrome recorder and copied it to cypress\downloads. Now when I run "npx @cypress/chrome-recorder cypress\downloads\login.json" OR "npx @cypress/chrome-recorder cypress\downloads\login.json --print" .

I am getting the error "There was an issue writing the output to cypress/integration. Please check that it exists and try again.". image

Can anybody help me on this. Thanks

admah commented 2 years ago

What version of the package are you using?

Puneet-humm commented 2 years ago

Hi Admah, I am using Cypress v 9.6.1 and chrome -recorder v 1.4.0

admah commented 2 years ago

@Puneet-humm does the cypress/integration folder exist? This won't write those folders. I've tested it with a similar file structure and can't reproduce what you're seeing.

Also, I'm removing the --print flag in favor of --dry. Try to run it with that flag to see the output.

Puneet-humm commented 2 years ago

@admah , yes cypress/integration folder exist. Attached is the screenshot showing which commands are failing and which are passing. --dry is running fine.

cypress

.

admah commented 2 years ago

@Puneet-humm for the first command try:

npx @cypress/chrome-recorder cypress/downloads/login.json --output=cypress/fixtures

There shouldn't be a space after --output=. Also, you're using \ for your paths instead of /.

Puneet-humm commented 2 years ago

What a silly thing I was doing, Its working now.

Thanks a lot for your help :)