circleci-orb icon indicating copy to clipboard operation
circleci-orb copied to clipboard

Propose cypress/run as a command

Open lbesson-della opened this issue 5 years ago • 2 comments

Unless I'missing something there is no command equivalent to the run job.

In my case I would like to run a slack notification on whether the tests failed or not.

If I use the cypress/run job, the slack job cannot be run when the tests fail. If I want to create a job that runs the test and, as final step, runs the slack command, I have a lot of code to write to match the functionality of the cypress/run job.

Having a run command almost equivalent in terms of functionalitu to the run job, that would be great

lbesson-della avatar Jul 30 '20 08:07 lbesson-della

We would like this as well. It seems cypress/run is just a job so it can't be made into a reusable command. This means we have to copy the code to run the cypress/run job into multiple workflows. Having it run as a command would make things much more reusable.

traviscrist avatar May 05 '21 23:05 traviscrist

I'd also appreciate this. An equivalent run command would add value → flexibility and improve reuse. If not, thoughts on providing params to inject steps?

I appreciate y'all's consideration and providing this orb.

@lbesson-della for slack try using post-steps.

post-steps:
    - slack/notify:
          event: fail
          ...

kevnm67 avatar Jun 14 '22 23:06 kevnm67

Please try v3.0.0 of our orb. We have a cypress-command command where you pass the command to run Cypress as you normally would in a termianl.

cypress-command: 'npx cypress run --record --parallel'

We believe this offers more flexibility which may resolve your issue. Please open a new issue if 3.0.0 does not resolve your issue.

jennifer-shehane avatar Mar 01 '23 15:03 jennifer-shehane