From 66fe1de8368ba7e754fa6dad798bf351f3c3bf93 Mon Sep 17 00:00:00 2001 From: Lars Wirzenius Date: Fri, 19 Jan 2018 19:16:57 +0200 Subject: Change: builds are now numbered foo/123, as are logs --- ick2/projectapi_tests.py | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to 'ick2/projectapi_tests.py') diff --git a/ick2/projectapi_tests.py b/ick2/projectapi_tests.py index 4cca9e2..96242ef 100644 --- a/ick2/projectapi_tests.py +++ b/ick2/projectapi_tests.py @@ -58,12 +58,14 @@ class ProjectAPITests(unittest.TestCase): 'pipelines': ['build'], 'parameters': { 'foo': 'bar', - } + }, } api = self.create_api() - self.assertEqual(api.create(project), project) - self.assertEqual(api.list(), {'projects': [project]}) + new = api.create(project) + project['next_build_id'] = None + self.assertEqual(new, project) + self.assertEqual(api.list(), {'projects': [new]}) self.assertEqual(api.get_pipeline('foo', 'build'), {'status': 'idle'}) self.assertEqual(api.get_pipeline('foo', 'build'), {'status': 'idle'}) @@ -90,6 +92,7 @@ class ProjectAPITests(unittest.TestCase): project = { 'project': 'foo', 'pipelines': ['build'], + 'next_build_id': None, } api = self.create_api() api.create(project) @@ -101,6 +104,7 @@ class ProjectAPITests(unittest.TestCase): project = { 'project': 'foo', 'pipelines': ['build'], + 'next_build_id': None, } api = self.create_api() api.create(project) @@ -110,6 +114,7 @@ class ProjectAPITests(unittest.TestCase): project_v1 = { 'project': 'foo', 'pipelines': ['build'], + 'next_build_id': None, } project_v2 = dict(project_v1) project_v2['shell_steps'] = ['build it using magic'] -- cgit v1.2.1