assertAttributeEquals( array( 'type' => ezcDocumentOdtFormattingProperties::PROPERTIES_TEXT ), 'properties', $props ); } public function testAppendValueFailure() { $props = new ezcDocumentOdtFormattingProperties( ezcDocumentOdtFormattingProperties::PROPERTIES_TEXT ); try { $props->append( 'foo' ); $this->fail( 'Exception not thrown on invalid method call to append().' ); } catch ( RuntimeException $e ) {} } public function testExchangeArrayFailure() { $props = new ezcDocumentOdtFormattingProperties( ezcDocumentOdtFormattingProperties::PROPERTIES_TEXT ); try { $props->exchangeArray( array() ); $this->fail( 'Exception not thrown on invalid method call to exchangeArray().' ); } catch ( RuntimeException $e ) {} } public function testOffsetSetSuccess() { $props = new ezcDocumentOdtFormattingProperties( ezcDocumentOdtFormattingProperties::PROPERTIES_TEXT ); $props['foo'] = 23; $this->assertEquals( 23, $props['foo'] ); } public function testOffsetSetFailure() { $props = new ezcDocumentOdtFormattingProperties( ezcDocumentOdtFormattingProperties::PROPERTIES_TEXT ); try { $props[23] = 'foo'; $this->fail( 'Exception not thrown on invalid offset 23.' ); } catch ( ezcBaseValueException $e ) {} } } ?>