Summary: | assorted test failures | ||
---|---|---|---|
Product: | Wocky | Reporter: | Simon McVittie <smcv> |
Component: | General | Assignee: | Simon McVittie <smcv> |
Status: | RESOLVED FIXED | QA Contact: | Telepathy bugs list <telepathy-bugs> |
Severity: | major | ||
Priority: | high | CC: | guillaume.desmottes, vivek |
Version: | git master | Keywords: | patch |
Hardware: | Other | ||
OS: | All | ||
Whiteboard: | |||
i915 platform: | i915 features: | ||
Attachments: |
wocky-connector-test: stop putting sockets in blocking mode
wocky-xmpp-reader-test: don't assume non-characters will be replaced wocky-dummy-xmpp-server: don't turn off non-blocking on the socket Tests: don't assume that other things can sneak in ahead of cancellation some tests: give better diagnostics on failure |
Description
Simon McVittie
2013-08-08 12:22:23 UTC
Created attachment 83848 [details] [review] wocky-connector-test: stop putting sockets in blocking mode GSocket configures its underlying fd to be in non-blocking mode, and implements blocking calls by select()ing (or equivalent) first. If we break this assumption, most test cases in wocky-connector-test hang in a recv() that should have been non-blocking. Created attachment 83849 [details] [review] wocky-xmpp-reader-test: don't assume non-characters will be replaced GLib now follows Unicode Corrigendum 9, which clarifies that libraries shouldn't prohibit non-characters. We were assuming it did. --- See also Bug #63072, https://bugzilla.gnome.org/show_bug.cgi?id=694669 and Bug #63069. Created attachment 83850 [details] [review] wocky-dummy-xmpp-server: don't turn off non-blocking on the socket The very next thing we did with it was to give it to GSocketConnection, which would turn on non-blocking again; so this code wasn't doing anything except harming our portability. Created attachment 83851 [details] [review] Tests: don't assume that other things can sneak in ahead of cancellation The porter test asserted that if you cancelled the sending of a stanza after it had already been (sent and) received, the send reported success, not cancellation; and the SASL auth test asserted that if you closed a connection at around the same time that a cancellable had been cancelled, the close reported success, not cancellation. However, recent GLib seems to be either more careful about deferring the results of async operations to an idle, or more consistent about reporting the cancellation as an error even if the operation's success had already been recorded. As a result, these operations reported cancellation. To avoid that, delay the cancellation a little. Comment on attachment 83848 [details] [review] wocky-connector-test: stop putting sockets in blocking mode Review of attachment 83848 [details] [review]: ----------------------------------------------------------------- +1 Comment on attachment 83850 [details] [review] wocky-dummy-xmpp-server: don't turn off non-blocking on the socket Review of attachment 83850 [details] [review]: ----------------------------------------------------------------- +1 Comment on attachment 83851 [details] [review] Tests: don't assume that other things can sneak in ahead of cancellation Review of attachment 83851 [details] [review]: ----------------------------------------------------------------- +1 Created attachment 83855 [details] [review] some tests: give better diagnostics on failure --- I'd like to land the four patches above in the new gabble-0.18 branch and release them with Gabble 0.18, because it seems undesirable to be (effectively) stable-branching Wocky if it can't pass its own tests. This one should only go to Wocky master (after the branch point) though. Comment on attachment 83849 [details] [review] wocky-xmpp-reader-test: don't assume non-characters will be replaced Review of attachment 83849 [details] [review]: ----------------------------------------------------------------- +1 Comment on attachment 83855 [details] [review] some tests: give better diagnostics on failure Review of attachment 83855 [details] [review]: ----------------------------------------------------------------- +1 Fixed in git for telepathy-gabble 0.18.0, thanks. |
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.