File tree Expand file tree Collapse file tree 6 files changed +7
-16
lines changed Expand file tree Collapse file tree 6 files changed +7
-16
lines changed Original file line number Diff line number Diff line change @@ -244,7 +244,7 @@ func ExampleAllCompleted() {
244244 })
245245 fmt .Println (out )
246246 fmt .Println (err )
247- // Outputs :
247+ // Output :
248248 // [[1 <nil>] [expected error]]
249249 // function 1 error: expected error
250250}
Original file line number Diff line number Diff line change @@ -157,7 +157,6 @@ func BenchmarkParallel(b *testing.B) {
157157}
158158
159159func ExampleParallel () {
160- start := time .Now ()
161160 out , err := async .Parallel (2 , func () int {
162161 time .Sleep (50 * time .Millisecond )
163162 return 1
@@ -168,11 +167,9 @@ func ExampleParallel() {
168167 time .Sleep (50 * time .Millisecond )
169168 return 3
170169 })
171- fmt .Println (time .Since (start ))
172170 fmt .Println (out )
173171 fmt .Println (err )
174- // Outputs:
175- // 101.210974ms
172+ // Output:
176173 // [[1] [2] [3]]
177174 // <nil>
178175}
@@ -336,7 +333,6 @@ func BenchmarkParallelCompleted(b *testing.B) {
336333}
337334
338335func ExampleParallelCompleted () {
339- start := time .Now ()
340336 out , err := async .ParallelCompleted (2 , func () int {
341337 time .Sleep (50 * time .Millisecond )
342338 return 1
@@ -347,11 +343,9 @@ func ExampleParallelCompleted() {
347343 time .Sleep (50 * time .Millisecond )
348344 return 3
349345 })
350- fmt .Println (time .Since (start ))
351346 fmt .Println (out )
352347 fmt .Println (err )
353- // Outputs:
354- // 101.210974ms
348+ // Output:
355349 // [[1] [expected error] [3]]
356350 // function 1 error: expected error
357351}
Original file line number Diff line number Diff line change @@ -132,20 +132,17 @@ func BenchmarkRace(b *testing.B) {
132132}
133133
134134func ExampleRace () {
135- start := time .Now ()
136135 out , index , err := async .Race (func () int {
137136 time .Sleep (50 * time .Millisecond )
138137 return 1
139138 }, func () int {
140139 time .Sleep (20 * time .Millisecond )
141140 return 2
142141 })
143- fmt .Println (time .Since (start ))
144142 fmt .Println (out )
145143 fmt .Println (index )
146144 fmt .Println (err )
147- // Outputs:
148- // 20.678486ms
145+ // Output:
149146 // [2]
150147 // 1
151148 // <nil>
Original file line number Diff line number Diff line change @@ -153,7 +153,7 @@ func ExampleRetry() {
153153 fmt .Println (i )
154154 fmt .Println (out )
155155 fmt .Println (err )
156- // Outputs :
156+ // Output :
157157 // 3
158158 // [<nil>]
159159 // <nil>
Original file line number Diff line number Diff line change @@ -123,7 +123,7 @@ func ExampleUntil() {
123123 fmt .Println (i )
124124 fmt .Println (out )
125125 fmt .Println (err )
126- // Outputs :
126+ // Output :
127127 // 3
128128 // [3]
129129 // <nil>
Original file line number Diff line number Diff line change @@ -112,7 +112,7 @@ func ExampleWhile() {
112112 fmt .Println (i )
113113 fmt .Println (out )
114114 fmt .Println (err )
115- // Outputs :
115+ // Output :
116116 // 3
117117 // []
118118 // <nil>
You can’t perform that action at this time.
0 commit comments