File tree Expand file tree Collapse file tree 2 files changed +6
-0
lines changed Expand file tree Collapse file tree 2 files changed +6
-0
lines changed Original file line number Diff line number Diff line change 47
47
ScratchPad . recorded . should be_true
48
48
end
49
49
50
+ it "registers an handler doing nothing with :IGNORE" do
51
+ Signal . trap :HUP , :IGNORE
52
+ Process . kill ( :HUP , Process . pid ) . should == 1
53
+ end
54
+
50
55
it "ignores the signal when passed nil" do
51
56
Signal . trap :HUP , nil
52
57
Signal . trap ( :HUP , @saved_trap ) . should be_nil
Original file line number Diff line number Diff line change @@ -6,3 +6,4 @@ slow:Signal.trap the special EXIT signal code can unset the handler
6
6
slow:Signal.trap returns 'DEFAULT' for the initial SIGINT handler
7
7
slow:Signal.trap accepts 'SYSTEM_DEFAULT' and uses the OS handler for SIGPIPE
8
8
slow:Signal.trap allows to register a handler for all known signals, except reserved signals for which it raises ArgumentError
9
+ fails:Signal.trap registers an handler doing nothing with :IGNORE
You can’t perform that action at this time.
0 commit comments