public function testDecorator() { $stubMessage = new fpErrorNotifierMessage('Foo Title'); $mock = $this->getMockForAbstractClass('fpBaseErrorNotifierDecorator', array(), '', false); sfConfig::set('sf_notify_decorator', array('class' => get_class($mock))); $notifier = new fpErrorNotifier(new sfEventDispatcher()); $decorator = $notifier->decorator($stubMessage); $this->assertInstanceOf(get_class($mock), $decorator); $this->assertAttributeEquals($stubMessage, 'message', $decorator); }