@@ -17,12 +17,12 @@ public function promise_fulfills_with_a_value_of_a_specified_class(): void
17
17
$ deferred ->resolve (new MyClass ());
18
18
$ this ->assertPromiseFulfillsWithInstanceOf ($ deferred ->promise (), MyClass::class, 1 );
19
19
} catch (Exception $ exception ) {
20
- $ this ->assertRegExp (
20
+ $ this ->assertMatchesRegularExpression (
21
21
'/Failed asserting that promise fulfills with a value of class ' . preg_quote (MyClass::class, '/ ' ) .'/ ' ,
22
22
$ exception ->getMessage ()
23
23
);
24
24
25
- $ this ->assertRegExp (
25
+ $ this ->assertMatchesRegularExpression (
26
26
'/Failed asserting that .+ matches expected .+/ ' ,
27
27
$ exception ->getMessage ()
28
28
);
@@ -38,12 +38,12 @@ public function it_fails_when_promise_rejects(): void
38
38
$ deferred ->reject ();
39
39
$ this ->assertPromiseFulfillsWithInstanceOf ($ deferred ->promise (), MyClass::class, 1 );
40
40
} catch (Exception $ exception ) {
41
- $ this ->assertRegExp (
41
+ $ this ->assertMatchesRegularExpression (
42
42
'/Failed asserting that promise fulfills with a value of class ' . preg_quote (MyClass::class, '/ ' ) .'/ ' ,
43
43
$ exception ->getMessage ()
44
44
);
45
45
46
- $ this ->assertRegExp (
46
+ $ this ->assertMatchesRegularExpression (
47
47
'/Promise was rejected/ ' ,
48
48
$ exception ->getMessage ()
49
49
);
@@ -67,12 +67,12 @@ static function() use ($deferred){
67
67
68
68
$ this ->assertPromiseFulfillsWithInstanceOf ($ promise , MyClass::class, 1 );
69
69
} catch (Exception $ exception ) {
70
- $ this ->assertRegExp (
70
+ $ this ->assertMatchesRegularExpression (
71
71
'/Failed asserting that promise fulfills with a value of class ' . preg_quote (MyClass::class, '/ ' ) .'/ ' ,
72
72
$ exception ->getMessage ()
73
73
);
74
74
75
- $ this ->assertRegExp (
75
+ $ this ->assertMatchesRegularExpression (
76
76
'/Promise was cancelled due to timeout/ ' ,
77
77
$ exception ->getMessage ()
78
78
);
0 commit comments