Permalink
Browse files

Add a slow spec to try out profiling

  • Loading branch information...
1 parent e437f26 commit 24932d1928b0788248fe28925442fbcc05018d99 @ferrous26 committed Jul 24, 2012
Showing with 14 additions and 2 deletions.
  1. +14 −2 spec/pride_spec.rb
View
@@ -2,6 +2,12 @@
require 'rspec/pride'
require 'stringio'
+RSpec.configure do |c|
+ if ENV['TEST_PROFILING']
+ c.profile_examples = true
+ end
+end
+
describe 'Some class' do
50.times do |n|
@@ -12,8 +18,14 @@
it 'should be pending'
- it 'should fail' do
- 1.should == 0
+ if ENV['TEST_PROFILING']
+ it 'should be really slow' do
+ sleep 2
+ end
+ else
+ it 'should fail' do
+ 1.should == 0
+ end
end
10.times do |n|

0 comments on commit 24932d1

Please sign in to comment.