Add a new change type and use it when an unexpected time jump is detected in the scheduler to reset reference times, offset and slewing, NCR instances (with their polling interval), synchronization status, and drop all sourcestats, manual, refclock and RTC samples. This should make the recovery more graceful if the estimated jump has a large error (e.g. select didn't timeout, or after system suspend).
18 lines
306 B
Bash
Executable file
18 lines
306 B
Bash
Executable file
#!/bin/bash
|
|
|
|
. test.common
|
|
|
|
test_start "external time step"
|
|
|
|
min_sync_time=1500
|
|
max_sync_time=1550
|
|
|
|
for step in -1e2 1e2; do
|
|
# Make one step in 150th second
|
|
client_step="(* $step (equal 0.1 (sum 1.0) 150))"
|
|
run_test || test_fail
|
|
check_chronyd_exit || test_fail
|
|
check_sync || test_fail
|
|
done
|
|
|
|
test_pass
|