test: Fix potential functional tests timeout

Merged Hugo Beauzée-Luyssen requested to merge chouquette/medialibrary:fix_test_timeout into master

If the discoverer signals its completion right after the parser, we'd ignore the parser completion, causing the test to hand until it times out.

Merge request reports