@@ -65,7 +65,7 @@ public function shouldReduceValuesWithInitialPromise()
6565 When::reduce (
6666 array (1 , 2 , 3 ),
6767 $ this ->plus (),
68- new FulfilledPromise (1 )
68+ When:: resolve (1 )
6969 )->then ($ mock );
7070 }
7171
@@ -79,7 +79,7 @@ public function shouldReducePromisedValuesWithoutInitialValue()
7979 ->with ($ this ->identicalTo (6 ));
8080
8181 When::reduce (
82- array (new FulfilledPromise (1 ), new FulfilledPromise (2 ), new FulfilledPromise (3 )),
82+ array (When:: resolve (1 ), When:: resolve (2 ), When:: resolve (3 )),
8383 $ this ->plus ()
8484 )->then ($ mock );
8585 }
@@ -94,7 +94,7 @@ public function shouldReducePromisedValuesWithInitialValue()
9494 ->with ($ this ->identicalTo (7 ));
9595
9696 When::reduce (
97- array (new FulfilledPromise (1 ), new FulfilledPromise (2 ), new FulfilledPromise (3 )),
97+ array (When:: resolve (1 ), When:: resolve (2 ), When:: resolve (3 )),
9898 $ this ->plus (),
9999 1
100100 )->then ($ mock );
@@ -110,9 +110,9 @@ public function shouldReducePromisedValuesWithInitialPromise()
110110 ->with ($ this ->identicalTo (7 ));
111111
112112 When::reduce (
113- array (new FulfilledPromise (1 ), new FulfilledPromise (2 ), new FulfilledPromise (3 )),
113+ array (When:: resolve (1 ), When:: resolve (2 ), When:: resolve (3 )),
114114 $ this ->plus (),
115- new FulfilledPromise (1 )
115+ When:: resolve (1 )
116116 )->then ($ mock );
117117 }
118118
@@ -144,7 +144,7 @@ public function shouldReduceEmptyInputWithInitialPromise()
144144 When::reduce (
145145 array (),
146146 $ this ->plus (),
147- new FulfilledPromise (1 )
147+ When:: resolve (1 )
148148 )->then ($ mock );
149149 }
150150
@@ -158,9 +158,9 @@ public function shouldRejectWhenInputContainsRejection()
158158 ->with ($ this ->identicalTo (2 ));
159159
160160 When::reduce (
161- array (new FulfilledPromise (1 ), new RejectedPromise (2 ), new FulfilledPromise (3 )),
161+ array (When:: resolve (1 ), When:: reject (2 ), When:: resolve (3 )),
162162 $ this ->plus (),
163- new FulfilledPromise (1 )
163+ When:: resolve (1 )
164164 )->then ($ this ->expectCallableNever (), $ mock );
165165 }
166166
@@ -240,7 +240,7 @@ public function shouldAcceptAPromiseForAnArray()
240240 ->with ($ this ->identicalTo ('123 ' ));
241241
242242 When::reduce (
243- new FulfilledPromise (array (1 , 2 , 3 )),
243+ When:: resolve (array (1 , 2 , 3 )),
244244 $ this ->append (),
245245 ''
246246 )->then ($ mock );
@@ -256,7 +256,7 @@ public function shouldResolveToInitialValueWhenInputPromiseDoesNotResolveToAnArr
256256 ->with ($ this ->identicalTo (1 ));
257257
258258 When::reduce (
259- new FulfilledPromise (1 ),
259+ When:: resolve (1 ),
260260 $ this ->plus (),
261261 1
262262 )->then ($ mock );
0 commit comments