mirror of
https://github.com/golang/go.git
synced 2025-12-08 06:10:04 +00:00
move things out of sys into os and runtime
R=r OCL=28569 CL=28573
This commit is contained in:
parent
c367d1b789
commit
918afd9491
70 changed files with 243 additions and 174 deletions
|
|
@ -14,6 +14,8 @@ package testing
|
|||
import (
|
||||
"flag";
|
||||
"fmt";
|
||||
"os";
|
||||
"runtime";
|
||||
)
|
||||
|
||||
// Report as tests are run; default is silent for success.
|
||||
|
|
@ -47,7 +49,7 @@ func (t *T) Fail() {
|
|||
func (t *T) FailNow() {
|
||||
t.Fail();
|
||||
t.ch <- t;
|
||||
sys.Goexit();
|
||||
runtime.Goexit();
|
||||
}
|
||||
|
||||
// Log formats its arguments using default formatting, analogous to Print(),
|
||||
|
|
@ -129,7 +131,7 @@ func Main(tests []Test) {
|
|||
}
|
||||
if !ok {
|
||||
println("FAIL");
|
||||
sys.Exit(1);
|
||||
os.Exit(1);
|
||||
}
|
||||
println("PASS");
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue