def testMetaTagToAndFromString(self): self.method = webmastertools.VerificationMethod() self.method.type = 'metatag' self.method.in_use = 'false' self.assert_(self.method.type == 'metatag') self.assert_(self.method.in_use == 'false') self.method.meta = webmastertools.VerificationMethodMeta( name='verify-vf1', content='a2Ai') self.assert_(self.method.meta.name == 'verify-vf1') self.assert_(self.method.meta.content == 'a2Ai') new_method = webmastertools.VerificationMethodFromString( self.method.ToString()) self.assert_(self.method.type == new_method.type) self.assert_(self.method.in_use == new_method.in_use) self.assert_(self.method.meta.name == new_method.meta.name) self.assert_(self.method.meta.content == new_method.meta.content)
def setUp(self): self.meta = webmastertools.VerificationMethodMeta()