File tree Expand file tree Collapse file tree 1 file changed +0
-36
lines changed Expand file tree Collapse file tree 1 file changed +0
-36
lines changed Original file line number Diff line number Diff line change @@ -43,39 +43,3 @@ func TestWithCancel(t *testing.T) {
43
43
44
44
require .True (t , canceled )
45
45
}
46
-
47
- // type myDoneCtx struct {
48
- // Context
49
- // }
50
-
51
- // func (d *myDoneCtx) Done() Channel {
52
- // c := NewChannel()
53
- // return c
54
- // }
55
-
56
- // func TestWithOtherCancel(t *testing.T) {
57
- // canceled := false
58
-
59
- // var cancel CancelFunc
60
-
61
- // cr := NewCoroutine(Background(), func(ctx Context) {
62
- // var c2 Context
63
- // c2, cancel = WithCancel(&myDoneCtx{ctx})
64
-
65
- // s := NewSelector()
66
- // s.AddChannelReceive(c2.Done(), func(ctx Context, c Channel) {
67
- // canceled = true
68
- // })
69
- // s.Select(ctx)
70
- // })
71
-
72
- // cr.Execute()
73
- // require.False(t, cr.Finished())
74
-
75
- // cancel()
76
-
77
- // cr.Execute()
78
- // require.True(t, cr.Finished())
79
-
80
- // require.True(t, canceled)
81
- // }
You can’t perform that action at this time.
0 commit comments