[Product Launch] Rerun Failed Tests (circleci tests run)

If you’d be wiling to share it, @villelahdenvuo, can you paste the command you’re using with the circleci tests run tool? (obscure whatever path or project name information you’d like)

I think you could have the result you’re looking for (the list of values sent to the -spec flag comma separated) by using the tr translate tool, like so:

$ echo "arg1 arg2 arg3" | tr ' ' ',' | xargs -I {} cypress run -spec {}

cypress run -spec arg1,arg2,arg3

Removing the initial echo command, and having the contents of the --command flag be --command="tr ' ' ',' | xargs -I {} cypress run -spec {}".

The tool currently expects input to the tool to be space or newline delimited, but how it’s assembled or arranged for the specific test runner you’re using is very flexible, depending on your comfort and familiarity with built-in bash tools.

1 Like