Skip to content

Commit aad40bd

Browse files
committed
Remove with_full_reset method not to collide with global test reset
1 parent 134f620 commit aad40bd

File tree

4 files changed

+2
-20
lines changed

4 files changed

+2
-20
lines changed

spec/concurrent/configuration_spec.rb

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,6 @@
33
module Concurrent
44

55
describe Configuration do
6-
with_full_reset
7-
86
it 'creates a global timer pool' do
97
Concurrent.configuration.global_timer_set.should_not be_nil
108
Concurrent.configuration.global_timer_set.should respond_to(:post)

spec/concurrent/scheduled_task_spec.rb

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,6 @@
77
module Concurrent
88

99
describe ScheduledTask do
10-
with_full_reset
11-
1210
context 'behavior' do
1311

1412
# obligation
@@ -56,9 +54,9 @@ def execute_dereferenceable(subject)
5654
it_should_behave_like :dereferenceable
5755

5856
# observable
59-
57+
6058
subject{ ScheduledTask.new(0.1){ nil } }
61-
59+
6260
def trigger_observable(observable)
6361
observable.execute
6462
sleep(0.2)

spec/concurrent/timer_task_spec.rb

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,6 @@
55
module Concurrent
66

77
describe TimerTask do
8-
with_full_reset
9-
108
before(:each) do
119
# suppress deprecation warnings.
1210
Concurrent::TimerTask.any_instance.stub(:warn)

spec/support/example_group_extensions.rb

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -38,18 +38,6 @@ def kill_rogue_threads(warning = true)
3838
end
3939

4040
class RSpec::Core::ExampleGroup
41-
def self.with_full_reset
42-
before(:each) do
43-
reset_gem_configuration
44-
end
45-
46-
after(:each) do
47-
Thread.list.each do |thread|
48-
thread.kill unless thread == Thread.current
49-
end
50-
end
51-
end
52-
5341
include Concurrent::TestHelpers
5442
extend Concurrent::TestHelpers
5543
end

0 commit comments

Comments
 (0)