/** * Run test for getJson method * * @param array $incoming * @param string $outgoing * @dataProvider getJsonDataProvider */ public function testGetJson($incoming, $outgoing) { $this->readerMock->expects($this->once())->method('read')->willReturn($incoming); $this->assertEquals($outgoing, $this->resolutionRules->getJson()); }
/** * Run test for getJson method * * @return void */ public function testGetJson() { $expected = ['test' => 'test-value']; $this->readerMock->expects($this->once())->method('read')->willReturn($expected); $this->assertEquals(json_encode($expected), $this->resolutionRules->getJson()); }