Did I find the right examples for you? yes no

All Samples(19)  |  Call(19)  |  Derive(0)  |  Import(0)

src/p/y/python-ironicclient-0.1.4/ironicclient/tests/test_shell.py   python-ironicclient(Download)
        except SystemExit:
            exc_type, exc_value, exc_traceback = sys.exc_info()
            self.assertEqual(0, exc_value.code)
        finally:
            out = sys.stdout.getvalue()
    def test_debug(self):
        httplib2.debuglevel = 0
        self.shell('--debug help')
        self.assertEqual(1, httplib2.debuglevel)
 

src/p/y/python-ironicclient-0.1.4/ironicclient/tests/test_client.py   python-ironicclient(Download)
        client = get_client('1', **kwargs)
 
        self.assertEqual('KSCLIENT_AUTH_TOKEN', client.http_client.auth_token)
 
    def test_get_client_with_auth_token(self):
        client = get_client('1', **kwargs)
 
        self.assertEqual('USER_AUTH_TOKEN', client.http_client.auth_token)
 
    def test_get_client_no_url_and_no_token(self):

src/p/y/python-ironicclient-0.1.4/ironicclient/tests/test_http.py   python-ironicclient(Download)
    def test_url_generation_trailing_slash_in_base(self):
        client = http.HTTPClient('http://localhost/')
        url = client._make_connection_url('/v1/resources')
        self.assertEqual('/v1/resources', url)
 
    def test_url_generation_without_trailing_slash_in_base(self):
        client = http.HTTPClient('http://localhost')
        url = client._make_connection_url('/v1/resources')
        self.assertEqual('/v1/resources', url)
    def test_url_generation_prefix_slash_in_path(self):
        client = http.HTTPClient('http://localhost/')
        url = client._make_connection_url('/v1/resources')
        self.assertEqual('/v1/resources', url)
 
    def test_url_generation_without_prefix_slash_in_path(self):
        client = http.HTTPClient('http://localhost')
        url = client._make_connection_url('v1/resources')
        self.assertEqual('/v1/resources', url)
                                  client.json_request,
                                  'GET', '/v1/resources')
        self.assertEqual('Internal Server Error (HTTP 500)', str(error))
 
    def test_server_exception_msg_only(self):

src/p/y/python-ironicclient-0.1.4/ironicclient/tests/test_utils.py   python-ironicclient(Download)
| Key      | Value |
+----------+-------+
''', output_dict.getvalue())
 
    def test_args_array_to_dict(self):
        cleaned_dict = utils.args_array_to_dict(my_args,
                                                "matching_metadata")
        self.assertEqual({
            'matching_metadata': {'metadata.key': 'metadata_value'},
            'other': 'value'
        patch = utils.args_array_to_patch(my_args['op'],
                                          my_args['attributes'])
        self.assertEqual([{'op': 'add',
                           'value': 'bar',
                           'path': '/foo'},
        patch = utils.args_array_to_patch(my_args['op'],
                                          my_args['attributes'])
        self.assertEqual([{'op': 'remove', 'path': '/foo'},
                          {'op': 'remove', 'path': '/extra/bar'}], patch)
 

src/p/y/python-ironicclient-0.1.4/ironicclient/tests/v1/test_port_shell.py   python-ironicclient(Download)
               'uuid']
        act = actual.keys()
        self.assertEqual(sorted(exp), sorted(act))
 

src/p/y/python-ironicclient-0.1.4/ironicclient/tests/v1/test_node_shell.py   python-ironicclient(Download)
               'uuid']
        act = actual.keys()
        self.assertEqual(sorted(exp), sorted(act))
 

src/p/y/python-ironicclient-0.1.4/ironicclient/tests/v1/test_driver_shell.py   python-ironicclient(Download)
        exp = ['hosts', 'name']
        act = actual.keys()
        self.assertEqual(sorted(exp), sorted(act))
 

src/p/y/python-ironicclient-0.1.4/ironicclient/tests/v1/test_chassis_shell.py   python-ironicclient(Download)
        exp = ['created_at', 'description', 'extra', 'updated_at', 'uuid']
        act = actual.keys()
        self.assertEqual(sorted(exp), sorted(act))