def basic_json_schema(self, items_numbers: List[int] = None): """Prints a json schema based on data from `self.source` Args: items_numbers: array of item numbers to create a schema from """ maintenance.deprecate( "'Arche.basic_json_schema()' was deprecated in 2019.03.25 and " "will be removed in 2019.04.22.", replacement="Use 'basic_json_schema()' instead", gone_in="0.4.0", ) schema.basic_json_schema(self.source, items_numbers)
def test_basic_json_schema(mocker): mocked_create_js = mocker.patch( "arche.tools.schema.create_json_schema", return_value=schema, autospec=True ) assert schema_tools.basic_json_schema("235801/1/15", [0, 5]).raw == schema mocked_create_js.assert_called_once_with("235801/1/15", [0, 5])