public function testConvertSubscriptionFeedToAndFromStringV2() { $this->feed->transferFromXML($this->V2feedText); $this->feed->setMajorProtocolVersion(2); $feedXml = $this->feed->saveXML(); $newSubscriptionFeed = new Zend_Gdata_YouTube_SubscriptionFeed(); $newSubscriptionFeed->transferFromXML($feedXml); $newSubscriptionFeed->setMajorProtocolVersion(2); $this->verifyAllSamplePropertiesAreCorrectV2($newSubscriptionFeed); $newSubscriptionFeedXml = $newSubscriptionFeed->saveXML(); $this->assertEquals($feedXml, $newSubscriptionFeedXml); }
public function testConvertSubscriptionFeedToAndFromString() { $this->feed->transferFromXML($this->feedText); $entryXml = $this->feed->saveXML(); $newSubscriptionFeed = new Zend_Gdata_YouTube_SubscriptionFeed(); $newSubscriptionFeed->transferFromXML($entryXml); $this->verifyAllSamplePropertiesAreCorrect($newSubscriptionFeed); $newSubscriptionFeedXml = $newSubscriptionFeed->saveXML(); $this->assertEquals($entryXml, $newSubscriptionFeedXml); }