public function testFallbackIfEntryDoesNotExist() { $this->readerImpl->expects($this->at(0)) ->method('read') ->with(self::RES_DIR, 'en_GB') ->will($this->returnValue(self::$data)); $this->readerImpl->expects($this->at(1)) ->method('read') ->with(self::RES_DIR, 'en') ->will($this->returnValue(self::$fallbackData)); $this->assertSame('Lah', $this->reader->readEntry(self::RES_DIR, 'en_GB', array('Entries', 'Bam'))); }