Fixed flaky clock_unittest by using relative comparison.
Fixed flaky clock_unittest by using relative comparison.

ClockTest.NtpTime was checking that the two methods for getting the
system time are returning a value that is within a fixed error margin
(100 ms) of each other. Unfortunately, even such a wide margin was
sometimes exceeded on heavily loaded machines
(https://build.chromium.org/p/client.webrtc/builders/Mac%20Asan/builds/9235/steps/system_wrappers_unittests/logs/stdio).

This CL changes the test to sandwich clock->CurrentNtp() between
clock->CurrentNtpTimeInMilliseconds(). This way the test will pass no
matter how much time elapses between the two method calls, as long as
the clock is monotonic.

Repeated test runs showed that there may be 1 ms worth of rounding error
between the two methods of getting time, so we have to allow that.

BUG=None.

Review-Url: https://codereview.webrtc.org/2393063002
Cr-Original-Commit-Position: 972c6d2dc6dd5efdad1377c0d224e03eb8f276f7@{#14520}
Cr-Mirrored-From: https://chromium.googlesource.com/external/webrtc
Cr-Mirrored-Commit: de3f844a2099eaae32e61c87b509750c94215f59

Alkalyne/webrtctrunk,Alkalyne/webrtctrunk,Alkalyne/webrtctrunk,Alkalyne/webrtctrunk,Alkalyne/webrtctrunk,Alkalyne/webrtctrunk,Alkalyne/webrtctrunk,Alkalyne/webrtctrunk