Skip to content

curlhttpsrc: test_multiple_http_requests unit test is flaky

The test_multiple_http_requests in the curlhttpsrc unit test is unreliable, sometimes causing an error:

Unexpected critical/warning:
Trying to dispose element fakesink1, but it is in READY instead
of the NULL state.
You need to explicitly set elements to the NULL state before
dropping the final reference, to allow them to clean up.
This problem may also be caused by a refcounting bug in the
application or some element.

The test was using the bus watcher to move its source elements into the NULL state once they had completed 20 iterations. In some test environments this appears to be racy.

This commit changes the behaviour to perform the clean-up of the tests after the test has run, rather than doing some of the clean-up in the bus callback.

Fixes #932 (moved)

Merge request reports

Loading