Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Excluding a folder from autotesting

I've just installed a ZenTest to use autotest in my project. I use rspec and have an integration folder inside it. As I don't want all my integration tests run every single time I start autospec , so I'd like to somehow restrict autospec from running tests in that folder.

How do I exclude a chosen folder inside a /spec from running by autotest?

like image 759
gmile Avatar asked Apr 22 '10 11:04

gmile


1 Answers

You can tell autotest to ignore folders by editing the .autotest file in the root of your project:

Autotest.add_hook :initialize do |at|
  %w{.git vendor spec/integration}.each {|exception| at.add_exception(exception)}
end

This example will ignore the .git, vendor, and spec/integration folders and their descendants. You'll need to restart autospec to make the changes effective.

like image 93
zetetic Avatar answered Oct 30 '22 23:10

zetetic