| Conditions | 1 |
| Paths | 1 |
| Total Lines | 14 |
| Code Lines | 9 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 20 | public static function switching(array $data) |
||
| 21 | { |
||
| 22 | return (new QuickStart( |
||
| 23 | [ |
||
| 24 | new SwitchingMiddleware(), |
||
| 25 | new CommandSwitcherMiddleware(), |
||
| 26 | new DummyFallbackMiddleware(), |
||
| 27 | new DumpLogMiddleware(true), |
||
| 28 | ] |
||
| 29 | )) |
||
| 30 | ->addCommand(SomeCommand::class, true) |
||
| 31 | ->addCommand(SwitchedCommand::class) |
||
| 32 | ->setup(null, null, [], new Sender()) |
||
| 33 | ->handle(json_encode($data)); |
||
| 34 | } |
||
| 36 |