"Fossies" - the Fresh Open Source Software Archive

Member "chrony-3.5/test/simulation/101-poll" (10 May 2019, 684 Bytes) of package /linux/misc/chrony-3.5.tar.gz:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) Bash source code syntax highlighting (style: standard) with prefixed line numbers. Alternatively you can here view or download the uninterpreted source code file. See also the last Fossies "Diffs" side-by-side code changes report for "101-poll": 3.3_vs_3.4.

    1 #!/bin/bash
    2 
    3 . ./test.common
    4 test_start "minpoll/maxpoll options"
    5 
    6 wander=0.0
    7 jitter=1e-6
    8 
    9 time_max_limit=1e-5
   10 freq_max_limit=1e-5
   11 time_rms_limit=5e-6
   12 freq_rms_limit=5e-6
   13 client_conf="makestep 1e-2 1"
   14 
   15 for poll in $(seq 1 14); do
   16     client_server_options="minpoll $poll maxpoll $poll"
   17     limit=$[2**$poll * 10]
   18     min_sync_time=$[2**$poll * 2]
   19     max_sync_time=$[2**$poll * 21 / 10 + 1]
   20     client_max_min_out_interval=$(awk "BEGIN {print 2^$poll * 1.1}")
   21     client_min_mean_out_interval=$(awk "BEGIN {print 2^$poll * 0.99}")
   22 
   23     run_test || test_fail
   24     check_chronyd_exit || test_fail
   25     check_source_selection || test_fail
   26     check_packet_interval || test_fail
   27     check_sync || test_fail
   28 done
   29 
   30 test_pass