Part of lp.soyuz.scripts.tests.test_populatearchive View In Hierarchy
Method | runWrapperScript | Run populate-archive.py, returning the result and output. |
Method | getScript | Return an ArchivePopulator instance. |
Method | testCopyArchiveCreation | Start archive population, check data before and after. |
Method | runScript | Run the script to test. |
Method | testInvalidCopyArchiveName | Try copy archive creation/population with an invalid archive name. |
Method | testInvalidSuite | Try copy archive creation/population with a non-existent suite. |
Method | testInvalidUserName | Try copy archive population with an invalid user name. |
Method | testUnknownPackagesetName | Try copy archive population with an unknown packageset name. |
Method | testNonvirtualized | --nonvirtualized means the archive won't require virtualization. |
Method | testPackagesetDelta | Try to calculate the delta between two source package sets. |
Method | testMergeCopy | Try repeated copy archive population (merge copy). |
Method | testUnknownOriginArchive | Try copy archive population with a unknown origin archive. |
Method | testUnknownOriginPPA | Try copy archive population with an invalid PPA owner name. |
Method | testInvalidOriginArchiveName | Try copy archive population with an invalid origin archive name. |
Method | testInvalidProcessorName | Try copy archive population with an invalid architecture tag. |
Method | testProcessorsForExistingArchives | Try specifying processor names for existing archive. |
Method | testMissingCreationReason | Try copy archive population without a copy archive creation reason. |
Method | testMergecopyToMissingArchive | Try merge copy to non-existent archive. |
Method | testArchiveNameClash | Try creating an archive with same name and distribution twice. |
Method | testMissingProcessor | Try copy archive population without a single architecture tag. |
Method | testBuildsPendingAndSuspended | All builds in the new copy archive are pending and suspended. |
Method | testPrivateOriginArchive | Try copying from a private archive. |
Method | testDisabledDestinationArchive | Try copying to a disabled archive. |
Method | _verifyClonedSourcePackages | Verify that the expected source packages have been cloned. |
Method | _getPendingPackageNames | Undocumented |
Method | _prepareMergeCopy | Add a fresher and a new package to ubuntu/hoary. |
Method | _verifyPackagesInSampleData | Verify that the expected source packages are in the sample data. |
Inherited from TestCaseWithFactory:
Method | setUp | Undocumented |
Method | getUserBrowser | Return a Browser logged in as a fresh user, maybe opened at url . |
Method | getNonRedirectingBrowser | Undocumented |
Method | createBranchAtURL | Create a branch at the supplied URL. |
Method | create_branch_and_tree | Create a database branch, bzr branch and bzr checkout. |
Method | createBzrBranch | Create a bzr branch for a database branch. |
Static Method | getBranchPath | Return the path of the branch in the mirrored area. |
Method | useTempBzrHome | Undocumented |
Method | useBzrBranches | Prepare for using bzr branches. |
Inherited from TestCase (via TestCaseWithFactory):
Method | becomeDbUser | Commit, then log into the database as dbuser . |
Method | __str__ | The string representation of a test is its id. |
Method | useContext | Use the supplied context in this test. |
Method | makeTemporaryDirectory | Create a temporary directory, and return its path. |
Method | installKarmaRecorder | Set up and return a KarmaRecorder . |
Method | assertProvides | Assert 'obj' correctly provides 'interface'. |
Method | assertNotifies | Assert that a callable performs a given notification. |
Method | assertNoNotification | Assert that no notifications are generated by the callable. |
Method | assertSqlAttributeEqualsDate | Fail unless the value of the attribute is equal to the date. |
Method | assertTextMatchesExpressionIgnoreWhitespace | Undocumented |
Method | assertIsInstance | Assert that an instance is an instance of assert_class. |
Method | assertIsNot | Assert that expected is not the same object as observed . |
Method | assertContentEqual | Assert that 'iter1' has the same content as 'iter2'. |
Method | assertRaisesWithContent | Check if the given exception is raised with given content. |
Method | assertBetween | Assert that 'variable' is strictly between two boundaries. |
Method | assertVectorEqual | Apply assertEqual to all given pairs in one go. |
Method | expectedLog | Expect a log to be written that matches the regex. |
Method | pushConfig | Push some key-value pairs into a section of the config. |
Method | attachOopses | Undocumented |
Method | attachLibrarianLog | Include the logChunks from fixture in the test details. |
Method | assertStatementCount | Assert that the expected number of SQL statements occurred. |
Method | useTempDir | Use a temporary directory for this test. |
Method | assertEmailHeadersEqual | Assert that two email headers are equal. |
Method | assertStartsWith | Undocumented |
Method | assertEndsWith | Asserts that s ends with suffix. |
Method | checkPermissions | Check if the used_permissions match expected_permissions. |
Method | assertEmailQueueLength | Pop the email queue, assert its length, and return it. |
Method | _unfoldEmailHeader | Unfold a multiline email header. |
Runs the wrapper script using Popen(), returns a tuple of the process's return code, stdout output and stderr output.
Use the hoary-RELEASE suite along with the main component.
Parameters | archive_name | the name of the copy archive to create. (type: str ) |
suite | the name of the copy archive suite. (type: str ) | |
user | the name of the user creating the archive. (type: str ) | |
exists_before | copy archive with given name should
already exist if True. (type: bool ) | |
exists_after | the copy archive is expected to exist
after script invocation if True. (type: True ) | |
exception_type | the type of exception expected in case of failure. (type: type) | |
exception_text | expected exception text prefix in case
of failure. (type: str ) | |
extra_args | additional arguments to be passed to the script (if any). (type: list of strings) | |
copy_archive_name | optional copy archive instance, used for
merge copy testing. (type: IArchive ) | |
reason | if empty do not provide '--reason' cmd line arg to the script | |
output_substr | this must be part of the script's output |
When trying to create and populate a copy archive with an invalid name the script should fail with an appropriate error message.
A suite is a combination of a distro series and pocket e.g. hoary-updates or hardy-security. In the case where a non-existent suite is specified the script should abort with an appropriate error message.
The destination/copy archive will be created for some Launchpad user. If the user name passed is invalid the script should abort with an appropriate error message.
The caller can request copying specific packagesets. We test what happens if they request a packageset that doesn't exist.
In this (test) case an archive is populated twice and only fresher or new packages are copied to it.
This test should provoke a SoyuzScriptError
exception.
This test should provoke a SoyuzScriptError
exception.
This test should provoke a SoyuzScriptError
exception.
This test should provoke a SoyuzScriptError
exception.
The user is not supposed to specify processor on the command line for existing copy archives. The processor will be read from the database instead. Please see also the end of the testMultipleArchTags test.
This test should provoke a SoyuzScriptError
exception.
This test should provoke a SoyuzScriptError
exception because the
copy archive does not exist yet and will need to be created.
This is different from a merge copy scenario where the destination copy archive exists already and hence no archive creation reason is needed.
This test should provoke a SoyuzScriptError
exception because the
copy archive does not exist yet and we specified the '--merge-copy'
command line option. The latter specifies the repeated population of
existing archives.
This test should provoke a SoyuzScriptError
exception because there
is a uniqueness constraint based on (distribution, name) for all
non-PPA archives i.e. we do not allow the creation of a second archive
with the same name and distribution.
This test should provoke a SoyuzScriptError
exception.
This test should provoke a SoyuzScriptError
exception because
presently copy archives can only be created as public archives.
The copying of packages from private archives to public ones
thus constitutes a security breach.
This test should provoke a SoyuzScriptError
exception because
the destination archive is disabled.
The destination copy archive should be populated with the expected source packages.
Parameters | copy_archive | the destination copy archive to check. (type: Archive ) |
series | the destination distro series. (type: DistroSeries ) |