예제 #1
0
    def test_models_remove_by_job_id(self):
        """Tests if we can remove a job by id.
        """
        # Verify that the remove method can handle requests to remove objects
        # that don't exist
        result = models.remove_job_by_id(self.job_id)
        self.assertFalse(result)

        result = self.gen_test_job()
        self.assertTrue(result)

        result = models.remove_job_by_id(result.job_id)
        self.assertTrue(result)
예제 #2
0
    def test_models_remove_by_job_id(self):
        """Tests if we can remove a job by id.
        """
        # Verify that the remove method can handle requests to remove objects
        # that don't exist
        result = models.remove_job_by_id(self.job_id)
        self.assertFalse(result)

        result = self.gen_test_job()
        self.assertTrue(result)

        result = models.remove_job_by_id(result.job_id)
        self.assertTrue(result)
예제 #3
0
    def test_models_create_store_delete(self):
        """Test data model layer.
        """
        result = self.gen_test_job()

        self.assertTrue(result)

        result = models.remove_job_by_id(result.job_id)

        self.assertTrue(result)
예제 #4
0
    def test_models_create_store_delete(self):
        """Test data model layer.
        """
        result = self.gen_test_job()

        self.assertTrue(result)

        result = models.remove_job_by_id(result.job_id)

        self.assertTrue(result)