score field was dropped

This commit is contained in:
Mike McLean 2024-06-26 09:56:12 -04:00
parent 6cc8cbd936
commit b54a5f258d
2 changed files with 5 additions and 6 deletions

View file

@ -272,7 +272,7 @@ class RepoWatcher(object):
return check
def wait_request(self, req):
watch_fields = ('score', 'task_id', 'task_state', 'repo_id', 'active', 'tries')
watch_fields = ('task_id', 'task_state', 'repo_id', 'active', 'tries')
self.get_start()
watch_data = dict([(f, req.get(f)) for f in watch_fields])
while True:

View file

@ -51,7 +51,7 @@ class TestRepoWatcher(unittest.TestCase):
def test_waitrepo_request_wait(self):
repoinfo = {'id': 123, 'tag_id': self.TAG['id']}
req = {'id': 999, 'min_event': 10001, 'task_id': 'TASK', 'task_state': 0, 'repo_id': None,
'score': None, 'active': True, 'tries': 1}
'active': True, 'tries': 1}
self.session.repo.get.return_value = None
check = {'repo': None, 'request': req}
req2 = req.copy()
@ -74,7 +74,7 @@ class TestRepoWatcher(unittest.TestCase):
def test_waitrepo_request_timeout(self):
req = {'id': 999, 'min_event': 10001, 'task_id': 'TASK', 'task_state': 0, 'repo_id': None,
'score': None, 'active': True, 'tries': 1}
'active': True, 'tries': 1}
self.session.repo.get.return_value = None
check = {'repo': None, 'request': req}
self.session.repo.request.return_value = check
@ -107,7 +107,7 @@ class TestRepoWatcher(unittest.TestCase):
# once we report the build, checkForBuilds should be called just once more to verify the repo
req = {'id': 999, 'min_event': 10000, 'task_id': 'TASK', 'task_state': 0, 'repo_id': None,
'score': None, 'active': True, 'tries': 1}
'active': True, 'tries': 1}
check = {'repo': None, 'request': req}
self.session.repo.request.return_value = check
@ -156,8 +156,7 @@ class TestRepoWatcher(unittest.TestCase):
self.checkForBuilds.side_effect = my_check
req1 = {'id': 999, 'min_event': 10000, 'task_id': 'TASK', 'task_state': 0, 'repo_id': None,
'score': None}
req1 = {'id': 999, 'min_event': 10000, 'task_id': 'TASK', 'task_state': 0, 'repo_id': None}
req2 = req1.copy()
req2['min_event'] = 10002
repo1 = {'id': 123, 'tag_id': self.TAG['id'], 'create_event': 10000}