File tree Expand file tree Collapse file tree 3 files changed +20
-7
lines changed Expand file tree Collapse file tree 3 files changed +20
-7
lines changed Original file line number Diff line number Diff line change 44composer.lock
55.phpstorm.meta.php
66phpunit.xml
7- .phpunit.result.cache
7+ .phpunit. *
88.php_cs.cache
Original file line number Diff line number Diff line change 66
77class SslQueueTest extends TestCase
88{
9+ protected bool $ interactsWithConnection = false ;
10+
911 protected function setUp (): void
1012 {
13+ parent ::setUp ();
14+
1115 $ this ->markTestSkipped ();
1216 }
1317
Original file line number Diff line number Diff line change 1414
1515abstract class TestCase extends BaseTestCase
1616{
17+ /**
18+ * Set to false for skipped tests.
19+ */
20+ protected bool $ interactsWithConnection = true ;
21+
1722 /**
1823 * @throws AMQPProtocolChannelException
1924 */
2025 protected function setUp (): void
2126 {
2227 parent ::setUp ();
2328
24- if ($ this ->connection ()->isQueueExists ()) {
25- $ this ->connection ()->purge ();
29+ if ($ this ->interactsWithConnection ) {
30+ if ($ this ->connection ()->isQueueExists ()) {
31+ $ this ->connection ()->purge ();
32+ }
2633 }
2734 }
2835
@@ -31,11 +38,13 @@ protected function setUp(): void
3138 */
3239 protected function tearDown (): void
3340 {
34- if ($ this ->connection ()->isQueueExists ()) {
35- $ this ->connection ()->purge ();
36- }
41+ if ($ this ->interactsWithConnection ) {
42+ if ($ this ->connection ()->isQueueExists ()) {
43+ $ this ->connection ()->purge ();
44+ }
3745
38- self ::assertSame (0 , Queue::size ());
46+ self ::assertSame (0 , Queue::size ());
47+ }
3948
4049 parent ::tearDown ();
4150 }
You can’t perform that action at this time.
0 commit comments