1234567891011121314151617181920212223242526272829303132333435363738394041424344 |
- <?php
- namespace Fgm\ComposerCheck\Tests;
- use Fgm\ComposerCheck\JsonReporter;
- class JsonReporterTest extends ReporterTestBase {
-
- public function tearDown() {
- $this->reporter = new JsonReporter();
- parent::tearDown();
- }
-
- public function testEmptyReport() {
- $this->prophecy->getRows()->willReturn([]);
- $this->expected = '[]';
- }
-
- public function testNonEmptyReport() {
- $this->prophecy->getRows()->willReturn([
- 'dev' => [],
- 'run' => [],
- ]);
- $this->expected = <<<JSON
- {
- "dev": [],
- "run": []
- }
- JSON;
- }
- }
|