Reputation: 3
What is rails test command to exclude some test files or test name to be run?
For example, I want to exclude 1 rb test file which is test/integration/trello_webhook_test.rb I have try this commands:
rails test -t --ignore-testcase= "test/integration/trello_webhook_test.rb"
I give another try to exclude my test name contained "JSON" in trello_webhook_test.rb with this command:
rails test -t --ignore-name= "/JSON/"
But, both commands result in the test of trello_webhook_test.rb or the test name contained "/JSON/" was still run. Thanks in advance for any response.
the rails test --help: rails test --help output
I'm using Windows 10 OS.
Best, Randy
Upvotes: 0
Views: 1605
Reputation: 1796
According to help manual (rails test --help
) you have to do:
rails test --exclude test/integration/trello_webhook_test.rb
Upvotes: 1