def test_init(self): resource = Resource(self.url, self.auth) self.assertEqual(resource.url, self.url) self.assertEqual(resource.auth, self.auth) self.assertEqual(resource.headers, {'Content-type': 'application/json'})
def setUp(self): self.url = 'http://127.0.0.1:15672' self.host = '127.0.0.1' self.port = 15672 self.auth = ('guest', 'guest') self.resource = Resource(self.host, self.port, self.auth)
def setUp(self): self.url = 'http://127.0.0.1:15672' self.auth = ('guest', 'guest') self.resource = Resource(self.url, self.auth)