def setUp(self):
        self.ws = WebService(None)
        self.ws._client = FakeClient()
        self.ws.activated = True

        def password():
            return Password()

        self.ws.password_utility = password
        self.ws.username = '******'
 def setUp(self):
     self.url = utils.SOAP['soap_url']
     self.username = utils.SOAP['soap_username']
     self.password = utils.SOAP['soap_password']
     self.ws = WebService(None,
                          url=self.url,
                          username=self.username,
                          password=self.password,
                          activated=True)
     gsm = getGlobalSiteManager()
     passwordUtility = Password()
     gsm.registerUtility(passwordUtility, interfaces.IPasswordEncryption)
 def test_activated(self):
     ws = WebService(None)
     self.assertFalse(ws.activated)
     self.assertTrue(self.ws.activated)