[CDRIVER-1114] libmongoc tests fail with parallel enabled Created: 12/Feb/16  Updated: 10/Aug/16  Resolved: 18/Apr/16

Status: Closed
Project: C Driver
Component/s: libmongoc, tests
Affects Version/s: None
Fix Version/s: 1.4.0

Type: Bug Priority: Minor - P4
Reporter: A. Jesse Jiryu Davis Assignee: A. Jesse Jiryu Davis
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
is depended on by CDRIVER-1112 Upload test results to Evergreen Closed

 Description   

For as long as I've worked on the C Driver, we've had to disable test-libmongoc's "parallel" and "fork" options by passing "-f -p". Tests could finish faster, and could continue past test failures, if we fix the parallel and fork features.



 Comments   
Comment by Githook User [ 18/Apr/16 ]

Author:

{u'username': u'ajdavis', u'name': u'A. Jesse Jiryu Davis', u'email': u'jesse@mongodb.com'}

Message: CDRIVER-1114 remove threaded test option

The "parallel" option to run tests in multi-threaded mode hasn't worked
in recent memory. Rely on the default "forked" mode, which does work.
Branch: master
https://github.com/mongodb/mongo-c-driver/commit/5a1fe0548795847119503404a92e3dea01e21463

Comment by Hannes Magnusson [ 13/Feb/16 ]

Keeping this open as I can't find an actual ticket for parallel/threading mode being broken.
This means TEST_ARGS must include "-p".

It does so by default at the moment, but when providing custom options one must remember to include it which is annoying. e.g:

$ make test TEST_ARGS="-p -l /my/test"

Comment by Githook User [ 13/Feb/16 ]

Author:

{u'username': u'bjori', u'name': u'Hannes Magnusson', u'email': u'bjori@php.net'}

Message: CDRIVER-1114: fork() before running the tests

This allows us to always submit test results as per CDRIVER-1112
Branch: master
https://github.com/mongodb/mongo-c-driver/commit/01495b9692a4eab414da83b4c8d852871343512e

Comment by Hannes Magnusson [ 13/Feb/16 ]

I thought so too – but i just tested fork()ing now – and it works as expected. Its only the threading/parallel mode that doesn't work

This means we can remove the -p switch and let the test suite run to completion and saving the test-results.json all the time and graph out the failed tests for example.

The target still fails with error code (e.g. number of failed tests, lets hope that will never be 256!) so evergreen will realize the task failed

Generated at Wed Feb 07 21:11:36 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.