File tree Expand file tree Collapse file tree 3 files changed +9
-24
lines changed
pkg/enqueue-bundle/Tests/Functional/Events Expand file tree Collapse file tree 3 files changed +9
-24
lines changed Original file line number Diff line number Diff line change 15
15
*/
16
16
class AsyncListenerTest extends WebTestCase
17
17
{
18
- public function setUp ()
18
+ protected function tearDown ()
19
19
{
20
- parent ::setUp ();
20
+ parent ::tearDown ();
21
21
22
- /** @var AsyncListener $asyncListener */
23
- $ asyncListener = static ::$ container ->get ('enqueue.events.async_listener ' );
24
-
25
- $ asyncListener ->resetSyncMode ();
26
- static ::$ container ->get ('test_async_subscriber ' )->calls = [];
27
- static ::$ container ->get ('test_async_listener ' )->calls = [];
22
+ static ::$ container = null ;
28
23
}
29
24
30
25
public function testShouldNotCallRealListenerIfMarkedAsAsync ()
Original file line number Diff line number Diff line change 2
2
3
3
namespace Enqueue \Bundle \Tests \Functional \Events ;
4
4
5
- use Enqueue \AsyncEventDispatcher \AsyncListener ;
6
5
use Enqueue \AsyncEventDispatcher \AsyncProcessor ;
7
6
use Enqueue \Bundle \Tests \Functional \App \TestAsyncListener ;
8
7
use Enqueue \Bundle \Tests \Functional \App \TestAsyncSubscriber ;
18
17
*/
19
18
class AsyncProcessorTest extends WebTestCase
20
19
{
21
- public function setUp ()
20
+ protected function tearDown ()
22
21
{
23
- parent ::setUp ();
22
+ parent ::tearDown ();
24
23
25
- /** @var AsyncListener $asyncListener */
26
- $ asyncListener = static ::$ container ->get ('enqueue.events.async_listener ' );
27
-
28
- $ asyncListener ->resetSyncMode ();
24
+ static ::$ container = null ;
29
25
}
30
26
31
27
public function testCouldBeGetFromContainerAsService ()
Original file line number Diff line number Diff line change 2
2
3
3
namespace Enqueue \Bundle \Tests \Functional \Events ;
4
4
5
- use Enqueue \AsyncEventDispatcher \AsyncListener ;
6
5
use Enqueue \Bundle \Tests \Functional \App \TestAsyncListener ;
7
6
use Enqueue \Bundle \Tests \Functional \WebTestCase ;
8
7
use Enqueue \Client \TraceableProducer ;
15
14
*/
16
15
class AsyncSubscriberTest extends WebTestCase
17
16
{
18
- public function setUp ()
17
+ protected function tearDown ()
19
18
{
20
- parent ::setUp ();
19
+ parent ::tearDown ();
21
20
22
- /** @var AsyncListener $asyncListener */
23
- $ asyncListener = static ::$ container ->get ('enqueue.events.async_listener ' );
24
-
25
- $ asyncListener ->resetSyncMode ();
26
- static ::$ container ->get ('test_async_subscriber ' )->calls = [];
27
- static ::$ container ->get ('test_async_listener ' )->calls = [];
21
+ static ::$ container = null ;
28
22
}
29
23
30
24
public function testShouldNotCallRealSubscriberIfMarkedAsAsync ()
You can’t perform that action at this time.
0 commit comments