On null changes serialize the id as null
Currently it's serialized as "None" (the string).
Change-Id: I75a8aeb6b11d5700f03baef95527016877ff8f92
diff --git a/tests/test_scheduler.py b/tests/test_scheduler.py
index 48baaef..a92efea 100644
--- a/tests/test_scheduler.py
+++ b/tests/test_scheduler.py
@@ -2558,7 +2558,7 @@
for q in p['change_queues']:
for head in q['heads']:
for change in head:
- self.assertEqual(change['id'], 'None')
+ self.assertEqual(change['id'], None)
for job in change['jobs']:
status_jobs.add(job['name'])
self.assertIn('project-bitrot-stable-old', status_jobs)
diff --git a/zuul/model.py b/zuul/model.py
index 7fb81bc..440f3ba 100644
--- a/zuul/model.py
+++ b/zuul/model.py
@@ -722,11 +722,8 @@
class NullChange(Changeish):
is_reportable = False
- def __init__(self, project):
- super(NullChange, self).__init__(project)
-
def _id(self):
- return 'None'
+ return None
def equals(self, other):
return False