Ruby Rspec. Get list of all Test

后端 未结 2 2043
被撕碎了的回忆
被撕碎了的回忆 2021-02-14 01:12

I have some test on Rspec, which looks like this:

describe \"description\" do

before :each do
  do_before()
end

it \"something_1\" do
  ...
end

it \"something         


        
2条回答
  •  春和景丽
    2021-02-14 01:29

    There used to be a way to do this using the tag --dry-run, but that has been removed and no longer works.

    You can use the -fd which is for format = documentation. This will show you a long list of all the specs that you've done and what they look like. It does, however, still run the test and show you any errors you have in the process. That said it's still a great way to list of all of your tests.

提交回复
热议问题