diff --git a/test/test_api_usage.py b/test/test_api_usage.py index ac516ad45..2edc51dad 100644 --- a/test/test_api_usage.py +++ b/test/test_api_usage.py @@ -2637,7 +2637,9 @@ class TestBuildTriggers(ApiTestCase): self.assertEquals({'status': 'success', 'subdir': ['sometoken', 'foo', 'bar', 'meh']}, subdir_json) # Activate the trigger. - trigger_config = {} + trigger_config = { + 'build_source': 'somesource' + } activate_json = self.postJsonResponse(BuildTriggerActivate, params=dict(repository=ADMIN_ACCESS_USER + '/simple', trigger_uuid=trigger.uuid), data={'config': trigger_config}) @@ -2675,7 +2677,9 @@ class TestBuildTriggers(ApiTestCase): assert 'id' in start_json self.assertEquals("build-name", start_json['display_name']) - self.assertEquals(['bar'], start_json['job_config']['docker_tags']) + self.assertEquals(['bar'], start_json['tags']) + self.assertEquals('subdir', start_json['subdirectory']) + self.assertEquals('somesource', start_json['trigger']['build_source']) # Verify the metadata was added. build_obj = database.RepositoryBuild.get(database.RepositoryBuild.uuid == start_json['id']) @@ -2743,7 +2747,7 @@ class TestBuildTriggers(ApiTestCase): assert 'id' in start_json self.assertEquals("build-name", start_json['display_name']) - self.assertEquals(['bar'], start_json['job_config']['docker_tags']) + self.assertEquals(['bar'], start_json['tags']) class TestUserAuthorizations(ApiTestCase):