2012-09-20 00:15:58 |
Charles Kerr |
description |
I don't think that http://bazaar.launchpad.net/~indicator-applet-developers/dbus-test-runner/trunk.12.10/revision/39.1.46 is correct.
Ignore-return is to not look at the return value of a task to calculate whether the test passed or failed, and that's what it's used for in dbus_test_task_passed().
But the code in all_tasks_finished_helper() seems to exit a task whether it's finished or not. This could kill off incomplete tasks prematurely, and I'm not sure what 39.1.46 was for.
Found in dbusmenu's test-json, where the "--ignore-return" calls caused test-json-service to exit prematurely before test-json-client could even start. Or not. Depending on timing issues, the phase of the moon, and the polarity of the neutron flow. |
I don't think that http://bazaar.launchpad.net/~indicator-applet-developers/dbus-test-runner/trunk.12.10/revision/39.1.46 is correct.
Ignore-return is for a task to always pass regardless of its return value, and that's how dbus_test_task_passed() uses it.
But all_tasks_finished_helper() probably shouldn't look at it. If the last task(s) running are ignore-return, they'll be killed prematurely when all_tasks_finished_helper() leaves 'all_finished' as TRUE s.t. dbus_test_service_run() exits. This doesn't seem desirable and I'm not sure what 39.1.46 is for.
Found by dbusmenu's test-json exiting prematurely because all of its tasks were ignore-return. On my machine, test-json-server was exiting before test-json-client even started. Sometimes. Or not. Depending on timing issues, the phase of the moon, and the polarity of the neutron flow. |
|