X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/e1f0da5e2657adceb6bfec870f96ac7e604341a8..f98e0188777b3e2d229c968824b3e64307dae4e6:/services/dockercleaner/tests/test_cleaner.py diff --git a/services/dockercleaner/tests/test_cleaner.py b/services/dockercleaner/tests/test_cleaner.py index 9fbd3e3014..7580b0128a 100644 --- a/services/dockercleaner/tests/test_cleaner.py +++ b/services/dockercleaner/tests/test_cleaner.py @@ -1,8 +1,12 @@ #!/usr/bin/env python3 +# Copyright (C) The Arvados Authors. All rights reserved. +# +# SPDX-License-Identifier: AGPL-3.0 import collections import itertools import json +import os import random import tempfile import time @@ -437,6 +441,11 @@ class ConfigTestCase(unittest.TestCase): self.assertEqual('never', config['RemoveStoppedContainers']) self.assertEqual(1, config['Verbose']) + def test_args_no_config(self): + self.assertEqual(False, os.path.exists(cleaner.DEFAULT_CONFIG_FILE)) + config = cleaner.load_config(['--quota', '1G']) + self.assertEqual(1 << 30, config['Quota']) + class ContainerRemovalTestCase(unittest.TestCase): LIFECYCLE = ['create', 'attach', 'start', 'resize', 'die', 'destroy']