]:
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()
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",
)
final_file.close()
- if not settings["skipreadmedataupdate"]:
+ if settings["genreadmedata"]:
update_readme_data(
settings["readmedatafilename"],
extensions=extensions,