Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
go
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
go
Commits
932428a1
Commit
932428a1
authored
Oct 07, 2013
by
Joel Sing
Committed by
Ian Lance Taylor
Oct 07, 2013
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
os/signal: make test logs reflect reality
R=golang-dev, iant CC=golang-dev
https://golang.org/cl/14470043
parent
e67b0e68
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
src/pkg/os/signal/signal_test.go
src/pkg/os/signal/signal_test.go
+4
-4
No files found.
src/pkg/os/signal/signal_test.go
View file @
932428a1
...
...
@@ -36,8 +36,8 @@ func TestSignal(t *testing.T) {
Notify
(
c
,
syscall
.
SIGHUP
)
defer
Stop
(
c
)
t
.
Logf
(
"sighup..."
)
// Send this process a SIGHUP
t
.
Logf
(
"sighup..."
)
syscall
.
Kill
(
syscall
.
Getpid
(),
syscall
.
SIGHUP
)
waitSig
(
t
,
c
,
syscall
.
SIGHUP
)
...
...
@@ -45,18 +45,18 @@ func TestSignal(t *testing.T) {
c1
:=
make
(
chan
os
.
Signal
,
1
)
Notify
(
c1
)
t
.
Logf
(
"sigwinch..."
)
// Send this process a SIGWINCH
t
.
Logf
(
"sigwinch..."
)
syscall
.
Kill
(
syscall
.
Getpid
(),
syscall
.
SIGWINCH
)
waitSig
(
t
,
c1
,
syscall
.
SIGWINCH
)
// Send two more SIGHUPs, to make sure that
// they get delivered on c1 and that not reading
// from c does not block everything.
t
.
Logf
(
"sig
winch
..."
)
t
.
Logf
(
"sig
hup
..."
)
syscall
.
Kill
(
syscall
.
Getpid
(),
syscall
.
SIGHUP
)
waitSig
(
t
,
c1
,
syscall
.
SIGHUP
)
t
.
Logf
(
"sig
winch
..."
)
t
.
Logf
(
"sig
hup
..."
)
syscall
.
Kill
(
syscall
.
Getpid
(),
syscall
.
SIGHUP
)
waitSig
(
t
,
c1
,
syscall
.
SIGHUP
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment