예제 #1
0
 public function testSetProperty()
 {
     $this->assertNull($this->object->fill);
     $this->object->fillcolor = '#FFFFFF';
     $this->assertTrue($this->object->fill);
     $this->object->fill = false;
     $this->assertNull($this->object->fillcolor);
     $this->object->fillopacity = '1';
     $this->assertTrue($this->object->fill);
     $this->object->fill = 'no';
     $this->assertNull($this->object->fillopacity);
     $illegalfillvalue = 'ha-ha-ha';
     $this->assertFalse($this->object->setProperty('fill', $illegalfillvalue));
     $this->assertEquals($this->object->getErrorMessages(), array(\wfMessage('multimaps-element-illegal-value', 'fill', $illegalfillvalue, '"' . implode('", "', $this->object->getPropertyValidValues('fill')) . '"')->escaped()));
 }