public function testGetSet() { $mimes = ['foo' => 'application/x-foo', 'bar' => 'application/x-bar']; $guesser = new FileExtMimeTypeGuesser(); $this->assertNotEquals($mimes, $guesser->getMimes()); $this->assertNull($guesser->guess('bazz.bar')); $this->assertNull($guesser->guess('bazz.foo')); $guesser->setMimes($mimes); $this->assertEquals($mimes, $guesser->getMimes()); $this->assertEquals($mimes['bar'], $guesser->guess('bazz.bar')); $this->assertEquals($mimes['foo'], $guesser->guess('bazz.foo')); }