Skip to content

Commit

Permalink
Failing test case for interrupt handling.
Browse files Browse the repository at this point in the history
  • Loading branch information
ioquatix committed Aug 22, 2023
1 parent 0e94aa6 commit 3f11ce4
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions test/io/event/selector/interrupt.rb
Original file line number Diff line number Diff line change
Expand Up @@ -23,15 +23,17 @@
end
end

sleep(1.0)
# Wait for thread to enter the selector:
sleep(0.001) until thread.status == "sleep"

thread.raise(::Interrupt)

expect{thread.join}.to be_a(::Interrupt)
expect{thread.join(1.0)}.to raise_exception(::Interrupt)
end
end

IO::Event::Selector.constants.each do |name|
# next unless name =~ /Select/
klass = IO::Event::Selector.const_get(name)

describe(klass, unique: name) do
Expand Down

0 comments on commit 3f11ce4

Please sign in to comment.