Add missing unit tests for last commit

This commit is contained in:
Vladimir Diaz 2017-02-06 16:20:28 -05:00
parent 90155962a7
commit 7aff0572ba

View file

@ -123,6 +123,8 @@ def setUp(self):
# We are inheriting from custom class.
unittest_toolbox.Modified_TestCase.setUp(self)
self.repository_name = 'test_repository'
# Copy the original repository files provided in the test folder so that
# any modifications made to repository files are restricted to the copies.
# The 'repository_data' directory is expected to exist in 'tuf/tests/'.
@ -157,7 +159,7 @@ def setUp(self):
# Setting 'tuf.settings.repository_directory' with the temporary client
# directory copied from the original repository files.
tuf.settings.repository_directory = self.client_directory
tuf.settings.repositories_directory = self.client_directory
self.repository_mirrors = {'mirror1': {'url_prefix': url_prefix,
'metadata_path': 'metadata',
'targets_path': 'targets',
@ -165,7 +167,7 @@ def setUp(self):
# Create the repository instance. The test cases will use this client
# updater to refresh metadata, fetch target files, etc.
self.repository_updater = updater.Updater('test_repository',
self.repository_updater = updater.Updater(self.repository_name,
self.repository_mirrors)