@@ -29,7 +29,8 @@ public function testEmitsErrorEventWhenStderrIsNotEmpty(): void
2929
3030 $ emitter
3131 ->expects ($ this ->once ())
32- ->method ('testErrored ' );
32+ ->method ('testErrored ' )
33+ ->seal ();
3334
3435 $ this ->processor ($ emitter )->process (new Success ('testOne ' ), '' , 'error ' );
3536 }
@@ -39,10 +40,19 @@ public function testEmitsErrorEventWhenProcessResultCannotBeUnserialized(): void
3940 {
4041 $ emitter = $ this ->createMock (Emitter::class);
4142
43+ $ emitter
44+ ->expects ($ this ->once ())
45+ ->method ('childProcessErrored ' );
46+
4247 $ emitter
4348 ->expects ($ this ->once ())
4449 ->method ('testErrored ' );
4550
51+ $ emitter
52+ ->expects ($ this ->once ())
53+ ->method ('testFinished ' )
54+ ->seal ();
55+
4656 $ this ->processor ($ emitter )->process (new Success ('testOne ' ), '' , '' );
4757 }
4858
@@ -51,10 +61,19 @@ public function testEmitsErrorEventWhenProcessResultIsShorterThanExpectedNonce()
5161 {
5262 $ emitter = $ this ->createMock (Emitter::class);
5363
64+ $ emitter
65+ ->expects ($ this ->once ())
66+ ->method ('childProcessErrored ' );
67+
5468 $ emitter
5569 ->expects ($ this ->once ())
5670 ->method ('testErrored ' );
5771
72+ $ emitter
73+ ->expects ($ this ->once ())
74+ ->method ('testFinished ' )
75+ ->seal ();
76+
5877 $ this ->processor ($ emitter )->process (
5978 new Success ('testOne ' ),
6079 'too-short ' ,
@@ -68,10 +87,19 @@ public function testEmitsErrorEventWhenProcessResultNonceDoesNotMatchExpectedNon
6887 {
6988 $ emitter = $ this ->createMock (Emitter::class);
7089
90+ $ emitter
91+ ->expects ($ this ->once ())
92+ ->method ('childProcessErrored ' );
93+
7194 $ emitter
7295 ->expects ($ this ->once ())
7396 ->method ('testErrored ' );
7497
98+ $ emitter
99+ ->expects ($ this ->once ())
100+ ->method ('testFinished ' )
101+ ->seal ();
102+
75103 $ this ->processor ($ emitter )->process (
76104 new Success ('testOne ' ),
77105 '00000000000000000000000000000000payload ' ,
@@ -85,10 +113,19 @@ public function testEmitsErrorEventWhenProcessResultContainsOnlyExpectedNonceAnd
85113 {
86114 $ emitter = $ this ->createMock (Emitter::class);
87115
116+ $ emitter
117+ ->expects ($ this ->once ())
118+ ->method ('childProcessErrored ' );
119+
88120 $ emitter
89121 ->expects ($ this ->once ())
90122 ->method ('testErrored ' );
91123
124+ $ emitter
125+ ->expects ($ this ->once ())
126+ ->method ('testFinished ' )
127+ ->seal ();
128+
92129 $ this ->processor ($ emitter )->process (
93130 new Success ('testOne ' ),
94131 'abcdef0123456789abcdef0123456789 ' ,
0 commit comments