Re: [patch 5/5] Add tests for WL3127 slave side TCP address binding
stewart@mysql.com writes:
> +change master to master_bind='1.1.1.1'; > +connection master; > +insert into t1 values (3); > +save_master_pos; > +connection slave; > +start slave; > +--real_sleep 1 # wait for I/O thread to try connection
It is almost always wrong to use sleep in test cases (because of race
conditions). But in this case I think it will work. Since, the race is that if
the connection _does not_ fail (==bug), the test may or may not fail depending
on timing. If the code works, there is no race.
So should work, but please add a comment explaining this (ie. explain why the
race condition will not cause random failures if the feature is correctly
implemented).
--
MySQL Code Commits Mailing List
For list archives:
http://lists.mysql.com/commits
To unsubscribe:
http://lists.mysql.com/commits?unsub=lists@pantek.com
Received on Tue Oct 9 04:54:07 2007
This archive was generated by hypermail 2.1.8
: Thu Jul 03 2008 - 09:34:33 EDT
|