mirror of
https://github.com/StevenBlack/hosts.git
synced 2026-07-01 10:46:51 +00:00
use more succinct name for arg
This commit is contained in:
@@ -1268,16 +1268,6 @@ class TestFlushDnsCache(BaseStdout):
|
||||
]:
|
||||
self.assertIn(expected, output)
|
||||
|
||||
|
||||
def mock_path_join_robust(*args):
|
||||
# We want to hard-code the backup hosts filename
|
||||
# instead of parametrizing based on current time.
|
||||
if len(args) == 2 and args[1].startswith("hosts-"):
|
||||
return os.path.join(args[0], "hosts-new")
|
||||
else:
|
||||
return os.path.join(*args)
|
||||
|
||||
|
||||
class TestRemoveOldHostsFile(BaseMockDir):
|
||||
def setUp(self):
|
||||
super(TestRemoveOldHostsFile, self).setUp()
|
||||
|
||||
@@ -148,12 +148,12 @@ def main():
|
||||
help="Skip static localhost entries " "in the final hosts file.",
|
||||
)
|
||||
parser.add_argument(
|
||||
"--skip-readme-data-update",
|
||||
"-d",
|
||||
dest="skipreadmedataupdate",
|
||||
default=False,
|
||||
action="store_true",
|
||||
help="Skip update of readme data",
|
||||
"--genreadmedata",
|
||||
"-g",
|
||||
dest="genreadmedata",
|
||||
default=True,
|
||||
action="store_false",
|
||||
help="Skip generation of readmeData.json",
|
||||
)
|
||||
parser.add_argument(
|
||||
"--output",
|
||||
@@ -285,7 +285,7 @@ def main():
|
||||
)
|
||||
final_file.close()
|
||||
|
||||
if not settings["skipreadmedataupdate"]:
|
||||
if settings["genreadmedata"]:
|
||||
update_readme_data(
|
||||
settings["readmedatafilename"],
|
||||
extensions=extensions,
|
||||
|
||||
Reference in New Issue
Block a user