test_runnable_jobs_api failure

RESOLVED FIXED

Status

Tree Management
Treeherder: API
RESOLVED FIXED
a year ago
a year ago

People

(Reporter: rwood, Assigned: rwood)

Tracking

Details

Attachments

(1 attachment)

(Assignee)

Description

a year ago
When running all of the treeherder tests in my local treeherder vagrant environment (py.test tests/ -v), this test fails:
/tests/webapp/api/test_runnable_jobs_api.py
...
tests/webapp/api/test_runnable_jobs_api.py::test_runnable_jobs_api FAILED
...
E       assert {'meta': {'co...id': 1, ...}]} == {'meta': {'cou...id': 1, ...}]}
E         Common items:
E         {'meta': {u'count': 1, u'offset': 0, u'repository': u'test_treeherder_jobs'}}
E         Differing items:
E         {'results': [{'build_architecture': 'x86', 'build_os': 'b2g', 'build_platform': 'b2g-emu-jb', 'build_platform_id': 1, ...}]} != {'results': [{'build_architecture': 'x86', 'build_os': 'b2g', 'build_platform': 'b2g-emu-jb', 'build_platform_id': 1, ...}]}

Note: when running the test on it's own, it passes fine:
py.test tests/webapp/api/test_runnable_jobs_api.py

And when running the set of webapp/api tests, and they all pass:
vagrant ~/treeherder $ py.test tests/webapp/api/ -v
(In reply to Robert Wood [:rwood] from comment #0)
> When running all of the treeherder tests in my local treeherder vagrant
> environment (py.test tests/ -v), this test fails:
> /tests/webapp/api/test_runnable_jobs_api.py
> ...
> tests/webapp/api/test_runnable_jobs_api.py::test_runnable_jobs_api FAILED
> ...
> E       assert {'meta': {'co...id': 1, ...}]} == {'meta': {'cou...id': 1,
> ...}]}
> E         Common items:
> E         {'meta': {u'count': 1, u'offset': 0, u'repository':
> u'test_treeherder_jobs'}}
> E         Differing items:
> E         {'results': [{'build_architecture': 'x86', 'build_os': 'b2g',
> 'build_platform': 'b2g-emu-jb', 'build_platform_id': 1, ...}]} !=
> {'results': [{'build_architecture': 'x86', 'build_os': 'b2g',
> 'build_platform': 'b2g-emu-jb', 'build_platform_id': 1, ...}]}
> 
> Note: when running the test on it's own, it passes fine:
> py.test tests/webapp/api/test_runnable_jobs_api.py
> 
> And when running the set of webapp/api tests, and they all pass:
> vagrant ~/treeherder $ py.test tests/webapp/api/ -v

What else normally runs before test_runnable_jobs? It might be something in e.g. `tests/etl` that's causing the problem.
(Assignee)

Comment 2

a year ago
Yep exactly, I just narrowed it down, its def something in tests/etl
(Assignee)

Comment 3

a year ago
vagrant ~/treeherder$ py.test tests/etl/test_job_ingestion.py tests/webapp/api/test_runnable_jobs_api.py -v

Causes the failure
(Assignee)

Comment 4

a year ago
I *believe* it's this test case in tests/etl/test_job_ingestion.py

def test_ingest_job_with_updated_job_group(test_repository, failure_classifications,
                                           sample_data, mock_log_parser,
                                           result_set_stored):
(Assignee)

Updated

a year ago
Assignee: nobody → rwood
Status: NEW → ASSIGNED
Created attachment 8828940 [details] [review]
[treeherder] rwood-moz:bug1332695 > mozilla:master
(Assignee)

Updated

a year ago
Attachment #8828940 - Flags: review?(wlachance)
Comment on attachment 8828940 [details] [review]
[treeherder] rwood-moz:bug1332695 > mozilla:master

r+ for second iteration
Attachment #8828940 - Flags: review?(wlachance) → review+
(Assignee)

Updated

a year ago
Status: ASSIGNED → RESOLVED
Last Resolved: a year ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.