@@ -71,11 +71,7 @@ def test_list_schemas_sends_expected_request(self, mocker: MockerFixture) -> Non
7171 mocked_get = mocker .patch ("requests.get" )
7272
7373 # Act
74- self .client .metadata .list_schemas (
75- dataset = "GLBX.MDP3" ,
76- start_date = "2018-01-01" ,
77- end_date = "2021-01-01" ,
78- )
74+ self .client .metadata .list_schemas (dataset = "GLBX.MDP3" )
7975
8076 # Assert
8177 call = mocked_get .call_args .kwargs
@@ -84,8 +80,6 @@ def test_list_schemas_sends_expected_request(self, mocker: MockerFixture) -> Non
8480 == f"https://hist.databento.com/v{ db .API_VERSION } /metadata.list_schemas"
8581 )
8682 assert ("dataset" , "GLBX.MDP3" ) in call ["params" ]
87- assert ("start_date" , "2018-01-01" ) in call ["params" ]
88- assert ("end_date" , "2021-01-01" ) in call ["params" ]
8983 assert sorted (call ["headers" ].keys ()) == ["accept" , "user-agent" ]
9084 assert call ["headers" ]["accept" ] == "application/json"
9185 assert all (
@@ -123,53 +117,6 @@ def test_list_fields_sends_expected_request(self, mocker: MockerFixture) -> None
123117 assert call ["timeout" ] == (100 , 100 )
124118 assert isinstance (call ["auth" ], requests .auth .HTTPBasicAuth )
125119
126- @pytest .mark .skipif (sys .version_info < (3 , 8 ), reason = "incompatible mocking" )
127- def test_list_encodings_sends_expected_request (self , mocker : MockerFixture ) -> None :
128- # Arrange
129- mocked_get = mocker .patch ("requests.get" )
130-
131- # Act
132- self .client .metadata .list_encodings ()
133-
134- # Assert
135- call = mocked_get .call_args .kwargs
136- assert (
137- call ["url" ]
138- == f"https://hist.databento.com/v{ db .API_VERSION } /metadata.list_encodings"
139- )
140- assert sorted (call ["headers" ].keys ()) == ["accept" , "user-agent" ]
141- assert call ["headers" ]["accept" ] == "application/json"
142- assert all (
143- v in call ["headers" ]["user-agent" ] for v in ("Databento/" , "Python/" )
144- )
145- assert call ["timeout" ] == (100 , 100 )
146- assert isinstance (call ["auth" ], requests .auth .HTTPBasicAuth )
147-
148- @pytest .mark .skipif (sys .version_info < (3 , 8 ), reason = "incompatible mocking" )
149- def test_list_compressions_sends_expected_request (
150- self ,
151- mocker : MockerFixture ,
152- ) -> None :
153- # Arrange
154- mocked_get = mocker .patch ("requests.get" )
155-
156- # Act
157- self .client .metadata .list_compressions ()
158-
159- # Assert
160- call = mocked_get .call_args .kwargs
161- assert (
162- call ["url" ]
163- == f"https://hist.databento.com/v{ db .API_VERSION } /metadata.list_compressions" # noqa
164- )
165- assert sorted (call ["headers" ].keys ()) == ["accept" , "user-agent" ]
166- assert call ["headers" ]["accept" ] == "application/json"
167- assert all (
168- v in call ["headers" ]["user-agent" ] for v in ("Databento/" , "Python/" )
169- )
170- assert call ["timeout" ] == (100 , 100 )
171- assert isinstance (call ["auth" ], requests .auth .HTTPBasicAuth )
172-
173120 @pytest .mark .skipif (sys .version_info < (3 , 8 ), reason = "incompatible mocking" )
174121 @pytest .mark .parametrize (
175122 "dataset, schema, mode" ,
0 commit comments