diff options
author | Josh MacDonald <josh.macdonald@gmail.com> | 2015-12-27 22:12:34 -0800 |
---|---|---|
committer | Josh MacDonald <josh.macdonald@gmail.com> | 2015-12-27 22:12:34 -0800 |
commit | ec9905aa755eafb64f08fc59ca7e67ea57498264 (patch) | |
tree | 304cae17d7d856c3ef465f7fad18398347272970 /xdelta3/go/src/xdelta | |
parent | dbbc4c4a59bb805a828bd61640ec8ba88fe92871 (diff) | |
parent | cf662894ba5b3847f06fd44dfb91f4733d9196f4 (diff) |
Merge frmo origin
Diffstat (limited to 'xdelta3/go/src/xdelta')
-rw-r--r-- | xdelta3/go/src/xdelta/run.go | 3 | ||||
-rw-r--r-- | xdelta3/go/src/xdelta/tgroup.go | 4 |
2 files changed, 5 insertions, 2 deletions
diff --git a/xdelta3/go/src/xdelta/run.go b/xdelta3/go/src/xdelta/run.go index 6523a1c..448fabe 100644 --- a/xdelta3/go/src/xdelta/run.go +++ b/xdelta3/go/src/xdelta/run.go | |||
@@ -55,7 +55,8 @@ func (r *Runner) RunTest(name string, f func (t *TestGroup)) { | |||
55 | c := make(chan interface{}) | 55 | c := make(chan interface{}) |
56 | go func() { | 56 | go func() { |
57 | defer func() { | 57 | defer func() { |
58 | c <- recover() | 58 | rec := recover() |
59 | c <- rec | ||
59 | }() | 60 | }() |
60 | fmt.Println("Testing", name, "...") | 61 | fmt.Println("Testing", name, "...") |
61 | f(t) | 62 | f(t) |
diff --git a/xdelta3/go/src/xdelta/tgroup.go b/xdelta3/go/src/xdelta/tgroup.go index b1b04ec..602b1e1 100644 --- a/xdelta3/go/src/xdelta/tgroup.go +++ b/xdelta3/go/src/xdelta/tgroup.go | |||
@@ -58,7 +58,9 @@ func (g *Goroutine) OK() { | |||
58 | 58 | ||
59 | func (g *Goroutine) Panic(err error) { | 59 | func (g *Goroutine) Panic(err error) { |
60 | g.finish(err) | 60 | g.finish(err) |
61 | runtime.Goexit() | 61 | if g != g.TestGroup.main { |
62 | runtime.Goexit() | ||
63 | } | ||
62 | } | 64 | } |
63 | 65 | ||
64 | func (t *TestGroup) Main() *Goroutine { return t.main } | 66 | func (t *TestGroup) Main() *Goroutine { return t.main } |