/** * @expectedException \InvalidArgumentException */ public function testSetFormatThrowInvalidArgumentException() { $canvas = new Canvas(); $canvas->setFormat('unknown Format'); }