/** * @group CoreFunctions * @covers FluentDOMCore::unique */ public function testUniqueWithObjectExpectingException() { $fd = new FluentDOM(); try { $fd->unique(array(new stdClass())); $this->fail('An expected exception has not been raised.'); } catch (InvalidArgumentException $expected) { $this->assertEquals('Array must only contain dom nodes, found "stdClass".', $expected->getMessage()); } }