Skip to content

Commit

Permalink
Break down test suites by operation type
Browse files Browse the repository at this point in the history
This is new, I previously managed this more manually. Running all tests will usually
take 5 minutes on a LAN, so this was added so that only important tests could be run
for quick iteration. Of course, the full suite should be run before a release.
  • Loading branch information
ferrous26 committed Sep 13, 2011
1 parent f311e5c commit 635b200
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 1 deletion.
1 change: 0 additions & 1 deletion Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@ end
require 'rake/testtask'
Rake::TestTask.new(:test) do |t|
t.libs << 'test'
t.pattern = 'test/**/test_*.rb'
t.ruby_opts = ['-rhelper.rb']
t.verbose = true
end
Expand Down
20 changes: 20 additions & 0 deletions test/helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -43,3 +43,23 @@ def assert_instance_of_boolean value, msg = nil
end

end


basic = ['login_test', 'logout_test']
create = ['attachments_test']
read = basic + []
update = []
delete = []
all = basic + create + read + update + delete

# Look at environment variables to decide which tests to run
tests = case ENV['JIRASOAP']
when 'all' then all
when 'basic' then basic
when 'create' then create
when 'read' then read
when 'update' then update
when 'delete' then delete
else read # hmm, for safeties sake, but maybe it should be all...
end
tests.each do |test| require test end

0 comments on commit 635b200

Please sign in to comment.