From: <svn...@op...> - 2009-03-26 16:54:15
|
Author: bellmich Date: Thu Mar 26 17:54:02 2009 New Revision: 1022 URL: http://libsyncml.opensync.org/changeset/1022 Log: fixed a race condition in the manager_receive test Modified: trunk/tests/check_manager.c Modified: trunk/tests/check_manager.c ============================================================================== --- trunk/tests/check_manager.c Thu Mar 26 17:38:21 2009 (r1021) +++ trunk/tests/check_manager.c Thu Mar 26 17:54:02 2009 (r1022) @@ -218,7 +218,14 @@ usleep(100); } - sml_fail_unless(transport_errors == 0, NULL); + /* If the server disconnects actively without a response + * then the service is unavailable. + * The HTTP server transport sends status 503 in this case. + * This is a transport error. + * If the machine is fast enough or a SMP machine + * then the transport error is signalled fast enough. + */ + sml_fail_unless(transport_errors <= 1, NULL); sml_fail_unless(num_sessions == 0, NULL); sml_fail_unless(num_finals == 0, NULL); sml_fail_unless(num_end == 0, NULL); |