Пример #1
0
    def test_instantiate_for_read_access(self):
        """Testing if instantiating with default handle server works
        and if a handle is correctly retrieved. """

        # Create client instance with username and password
        inst = RESTHandleClient.instantiate_for_read_access(HTTPS_verify=self.https_verify)
        rec = self.inst.retrieve_handle_record_json(self.handle)
        self.assertIsInstance(inst, RESTHandleClient)
        self.assertIn('handle', rec,
            'Response lacks "handle".')
        self.assertIn('responseCode', rec,
            'Response lacks "responseCode".')
    def test_instantiate_for_read_access(self):
        """Testing if instantiating with default handle server works. """

        # Create client instance with username and password
        inst = RESTHandleClient.instantiate_for_read_access()
        self.assertIsInstance(inst, RESTHandleClient)