@@ -57,23 +57,21 @@ def test_default(self, mocker):
57
57
session_mock .return_value .verify is True
58
58
59
59
def test_trailing_slash_removal (self , mocker ):
60
- session_mock = mocker .patch ("requests.Session" )
61
-
62
60
client = DummyClient ("https://my.url/" )
63
61
64
62
assert client .address == "https://my.url"
65
63
66
64
def test_kill_verification (self , mocker ):
67
65
session_mock = mocker .patch ("requests.Session" )
68
66
69
- client = DummyClient ("https://my.url" , verify = False )
67
+ DummyClient ("https://my.url" , verify = False )
70
68
71
69
session_mock .return_value .verify is False
72
70
73
71
def test_use_custom_ca_bundle_for_verification (self , mocker ):
74
72
session_mock = mocker .patch ("requests.Session" )
75
73
76
- client = DummyClient ("https://my.url" , ca_path = "some_path" )
74
+ DummyClient ("https://my.url" , ca_path = "some_path" )
77
75
78
76
session_mock .return_value .verify == "some_path"
79
77
@@ -91,7 +89,7 @@ def test_optional_parameter_combinations(
91
89
):
92
90
session_mock = mocker .patch ("requests.Session" )
93
91
94
- client = DummyClient ("https://my.url" , verify = verify , ca_path = ca_path )
92
+ DummyClient ("https://my.url" , verify = verify , ca_path = ca_path )
95
93
96
94
session_mock .return_value .verify == verify_result
97
95
@@ -122,23 +120,23 @@ def test_right_method(self, requests_mock):
122
120
client .get ("/get/path" )
123
121
124
122
125
- class TestHTTPClientGet :
123
+ class TestHTTPClientPost :
126
124
def test_right_method (self , requests_mock ):
127
125
requests_mock .post ("https://my.url/post/path" )
128
126
client = DummyClient ("https://my.url" )
129
127
130
128
client .post ("/post/path" , dict (post = "data" ))
131
129
132
130
133
- class TestHTTPClientGet :
131
+ class TestHTTPClientPut :
134
132
def test_right_method (self , requests_mock ):
135
133
requests_mock .put ("https://my.url/put/path" )
136
134
client = DummyClient ("https://my.url" )
137
135
138
136
client .put ("/put/path" , dict (put = "data" ))
139
137
140
138
141
- class TestHTTPClientGet :
139
+ class TestHTTPClientDelete :
142
140
def test_right_method (self , requests_mock ):
143
141
requests_mock .delete ("https://my.url/delete/path" )
144
142
client = DummyClient ("https://my.url" )
0 commit comments