Rails

A Few Ways To Run Your MiniTest Tests

Posted by Weston Ganger on December 15, 2016

Sometime you may want to only run some specific test files or method with Minitest. Here’s a few ways to do so.


# run specific test file
rake test TEST=test/features/test_site.rb

# run specific test method
rake test TEST=test/features/test_site.rb TESTOPTS="--name=test_foobar -v"

# run a folder of files
rake test TEST=test/features/foobar/*.rb

# run a nested folder of files
rake test TEST=test/features/**/*.rb


Related External Links:


Posted in Rails and Tagged with minitest rails testing 


Need help on your next project or application?

I specialize in Ruby-on-Rails, AngularJS, Javascript, Bootstrap, and Hybrid Mobile Apps with Cordova & Ionic.

Contact Me

Recommended Posts