tests: Increase accuracy of wait_for function.

Old "wait_for n" behavior was to wait for
any amount of time between n-1 and n+0.1 seconds.

Now "wait_for n" waits for some arbitrary amount of time
between n and n+0.1 seconds.

Change-Id: I30c08edb0c7cfc3e283ca1289f84dd6397523c23