Part of lp.services.job.tests.test_job View In Hierarchy
Method | test_implements_IJob | Job should implement IJob. |
Method | test_default_status | The default status should be WAITING. |
Method | test_stores_requester | Undocumented |
Method | test_createMultiple_creates_requested_number_of_jobs | Undocumented |
Method | test_createMultiple_returns_valid_job_ids | Undocumented |
Method | test_createMultiple_sets_status_to_WAITING | Undocumented |
Method | test_createMultiple_sets_requester | Undocumented |
Method | test_createMultiple_defaults_requester_to_None | Undocumented |
Method | test_start | Job.start should update the object appropriately. |
Method | test_start_increments_attempt_count | Job.start should increment the attempt count. |
Method | test_start_when_completed_is_invalid | When a job is completed, attempting to start is invalid. |
Method | test_start_when_failed_is_invalid | When a job is failed, attempting to start is invalid. |
Method | test_start_when_running_is_invalid | When a job is running, attempting to start is invalid. |
Method | test_complete | Job.complete should update the Job appropriately. |
Method | test_complete_when_waiting_is_invalid | When a job is waiting, attempting to complete is invalid. |
Method | test_complete_when_completed_is_invalid | When a job is completed, attempting to complete is invalid. |
Method | test_complete_when_failed_is_invalid | When a job is failed, attempting to complete is invalid. |
Method | test_fail | Job.fail should update the Job appropriately. |
Method | test_fail_when_waiting_is_invalid | When a job is waiting, attempting to fail is invalid. |
Method | test_fail_when_completed_is_invalid | When a job is completed, attempting to fail is invalid. |
Method | test_fail_when_failed_is_invalid | When a job is failed, attempting to fail is invalid. |
Method | test_queue | Job.queue should update the job appropriately. |
Method | test_queue_clears_lease_expires | Queueing a job releases its lease. |
Method | test_suspend | A job that is in the WAITING state can be suspended. |
Method | test_suspend_when_running | When a job is running, attempting to suspend is valid. |
Method | test_suspend_when_completed | When a job is completed, attempting to suspend is invalid. |
Method | test_suspend_when_failed | When a job is failed, attempting to suspend is invalid. |
Method | test_resume | A job that is suspended can be resumed. |
Method | test_resume_clears_lease_expires | A job that resumes should null out the lease_expires. |
Method | test_resume_when_running | When a job is running, attempting to resume is invalid. |
Method | test_resume_when_completed | When a job is completed, attempting to resume is invalid. |
Method | test_resume_when_failed | When a job is failed, attempting to resume is invalid. |
Method | test_is_pending | is_pending is True when the job can possibly complete. |
Method | test_is_runnable_when_failed | is_runnable is false when the job is not WAITING. |
Method | test_is_runnable_when_scheduled_in_future | is_runnable is false when the job is scheduled in the future. |
Method | test_is_runnable_when_scheduled_in_past | is_runnable is true when the job is scheduled in the past. |
Method | test_is_runnable_when_not_scheduled | is_runnable is true when no explicit schedule has been requested. |
Method | test_start_manages_transactions | Undocumented |
Method | test_complete_manages_transactions | Undocumented |
Method | test_fail_manages_transactions | Undocumented |
Method | test_queue_manages_transactions | Undocumented |
Method | test_suspend_manages_transactions | Undocumented |
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. |
It should set date_started, clear date_finished, and set the status to RUNNING.
It should set date_finished and set the job status to COMPLETED.
It should set date_finished and set the job status to FAILED.
It should set date_finished, and set status to WAITING.