X-Git-Url: https://git.openstreetmap.org./nominatim.git/blobdiff_plain/e9efef90954cba09fdba3e556e9efff75540071c..2c8fb31381def167adcee4c660c17c89a40f2de7:/test/python/cli/test_cmd_admin.py?ds=inline diff --git a/test/python/cli/test_cmd_admin.py b/test/python/cli/test_cmd_admin.py index 20e5be00..45104ea6 100644 --- a/test/python/cli/test_cmd_admin.py +++ b/test/python/cli/test_cmd_admin.py @@ -36,9 +36,14 @@ def test_admin_migrate(cli_call, mock_func_factory): def test_admin_clean_deleted_relations(cli_call, mock_func_factory): mock = mock_func_factory(nominatim.tools.admin, 'clean_deleted_relations') - assert cli_call('admin', '--clean-deleted') == 0 + assert cli_call('admin', '--clean-deleted', '1 month') == 0 assert mock.called == 1 +def test_admin_clean_deleted_relations_no_age(cli_call, mock_func_factory): + mock = mock_func_factory(nominatim.tools.admin, 'clean_deleted_relations') + + assert cli_call('admin', '--clean-deleted') == 1 + class TestCliAdminWithDb: @pytest.fixture(autouse=True)