public function testInvalidXml() { $this->setExpectedException('PHPUnit_Framework_ExpectationFailedException'); $this->setStubResponse('<xml><name>John</surname></xml>'); $this->module->seeResponseIsXml(); }