Ejemplo n.º 1
0
 def testJIDBareUser(self):
     """Test setting the bare JID with a user."""
     j = JID('user@domain/resource')
     j.bare = 'otheruser@otherdomain'
     self.check_jid(j, 'otheruser', 'otherdomain', 'resource',
                    'otheruser@otherdomain',
                    'otheruser@otherdomain/resource',
                    'otheruser@otherdomain/resource')
Ejemplo n.º 2
0
 def testJIDBareNoUser(self):
     """Test setting the bare JID without a user."""
     j = JID('user@domain/resource')
     j.bare = 'otherdomain'
     self.check_jid(j,
                    '',
                    'otherdomain',
                    'resource',
                    'otherdomain',
                    'otherdomain/resource',
                    'otherdomain/resource')