1 | <?php |
||
8 | class DumpCommandTest extends CommandTestCase |
||
9 | { |
||
10 | /** |
||
11 | * Test simple execute of dump command to standard output. |
||
12 | */ |
||
13 | public function testExecuteToStandardOutput() |
||
14 | { |
||
15 | $exitCode = $this->tester->run( |
||
16 | array( |
||
17 | 'command' => DumpCommand::COMMAND_NAME |
||
18 | ), |
||
19 | array( |
||
20 | 'verbosity' => OutputInterface::VERBOSITY_DEBUG |
||
21 | ) |
||
22 | ); |
||
23 | |||
24 | $display = trim($this->tester->getDisplay()); |
||
25 | |||
26 | $this->assertEquals(0, $exitCode, $display); |
||
27 | |||
28 | $this->assertRegExp( |
||
29 | '/-- Dump completed on/', |
||
30 | $display, |
||
31 | 'Wrong output of dump command detected. Did it print the SQL dump?' |
||
32 | ); |
||
33 | } |
||
34 | |||
35 | /** |
||
36 | * Test simple execute of dump command to file. |
||
37 | * |
||
38 | * @param bool $compress |
||
39 | * |
||
40 | * @dataProvider getCompressedOptions |
||
41 | */ |
||
42 | public function testExecuteToFile($compress) |
||
70 | |||
71 | /** |
||
72 | * @return array|boolean[][] |
||
73 | */ |
||
74 | public function getCompressedOptions() |
||
81 | } |
||
82 |