<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd">
<html lang="en">
<head>
<meta content="text/html; charset=utf-8" http-equiv="Content-Type">
<title>
GitLab
</title>



</head>
<body>
<style type="text/css">
img {
max-width: 100%; height: auto;
}
</style>
<div class="content">
<h3>
Ian Bruene pushed to branch wip-ntpq-peers-display
at <a href="https://gitlab.com/NTPsec/ntpsec">NTPsec / ntpsec</a>
</h3>
<h4>
Commits:
</h4>
<ul>
<li>
<strong><a href="https://gitlab.com/NTPsec/ntpsec/commit/ccc00e16bb0e2e3376cc7b19f22b844746669682">ccc00e16</a></strong>
<div>
<span>by Ian Bruene</span>
<i>at 2017-03-31T22:01:58-05:00</i>
</div>
<pre class="commit-message" style="margin: 0; white-space: pre-wrap">Added test for unitformatter.
</pre>
</li>
</ul>
<h4>1 changed file:</h4>
<ul>
<li class="file-stats">
<a href="#212369a2f3b2454ae6823fc589f4a77ae148f6cd">
tests/pylib/test_util.py
</a>
</li>
</ul>
<h4>Changes:</h4>
<li id="212369a2f3b2454ae6823fc589f4a77ae148f6cd">
<a href="https://gitlab.com/NTPsec/ntpsec/commit/ccc00e16bb0e2e3376cc7b19f22b844746669682#212369a2f3b2454ae6823fc589f4a77ae148f6cd"><strong>tests/pylib/test_util.py</strong></a>
<hr>
<table class="code white" style="-premailer-cellpadding: 0; -premailer-cellspacing: 0; -premailer-width: 100%; background: #fff; font-family: monospace; font-size: 12px" bgcolor="#fff" width="100%" cellpadding="0" cellspacing="0">
<tr class="line_holder match" id="" style="line-height: 1.6">
<td class="diff-line-num unfold js-unfold old_line" data-linenumber="90" style="background: #fafafa; border-right-color: #f0f0f0; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#fafafa">...</td>
<td class="diff-line-num unfold js-unfold new_line" data-linenumber="90" style="background: #fafafa; border-right-color: #f0f0f0; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#fafafa">...</td>
<td class="line_content match " style="background: #fafafa; color: rgba(0,0,0,0.3); padding-left: 0.5em; padding-right: 0.5em" bgcolor="#fafafa">@@ -90,5 +90,27 @@ class TestPylibUtilMethods(unittest.TestCase):</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6">
<td class="diff-line-num old_line" data-linenumber="90" style="background: #fafafa; border-right-color: #f0f0f0; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#fafafa">
90
</td>
<td class="diff-line-num new_line" data-linenumber="90" style="background: #fafafa; border-right-color: #f0f0f0; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#fafafa">
90
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em">
<pre style="margin: 0"> <span id="LC90" class="line">        <span class="bp" style="color: #999">self</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">assertEqual</span><span class="p">(</span><span class="n" style="color: #333">ntp</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">util</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">formatdigitsplit</span><span class="p">(</span><span class="o" style="font-weight: bold">-</span><span class="mf" style="color: #099">1.23456789</span><span class="p">,</span> <span class="mi" style="color: #099">6</span><span class="p">),</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6">
<td class="diff-line-num old_line" data-linenumber="91" style="background: #fafafa; border-right-color: #f0f0f0; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#fafafa">
91
</td>
<td class="diff-line-num new_line" data-linenumber="91" style="background: #fafafa; border-right-color: #f0f0f0; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#fafafa">
91
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em">
<pre style="margin: 0"> <span id="LC91" class="line">                         <span class="s" style="color: #d14">"</span><span class="si" style="color: #d14">%6.3</span><span class="s" style="color: #d14">f"</span><span class="p">)</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6">
<td class="diff-line-num old_line" data-linenumber="92" style="background: #fafafa; border-right-color: #f0f0f0; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#fafafa">
92
</td>
<td class="diff-line-num new_line" data-linenumber="92" style="background: #fafafa; border-right-color: #f0f0f0; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#fafafa">
92
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em">
<pre style="margin: 0"> <span id="LC92" class="line"></span>
</pre>
</td>
</tr>
<tr class="line_holder new" id="" style="line-height: 1.6">
<td class="diff-line-num new old_line" data-linenumber="93" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
 
</td>
<td class="diff-line-num new new_line" data-linenumber="93" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
93
</td>
<td class="line_content new noteable_line" style="background: #ecfdf0; padding-left: 0.5em; padding-right: 0.5em" bgcolor="#ecfdf0">
<pre style="margin: 0">+<span id="LC93" class="line">    <span class="k" style="font-weight: bold">def</span> <span class="nf" style="color: #900; font-weight: bold">test_unitformatter</span><span class="p">(</span><span class="bp" style="color: #999">self</span><span class="p">):</span></span>
</pre>
</td>
</tr>
<tr class="line_holder new" id="" style="line-height: 1.6">
<td class="diff-line-num new old_line" data-linenumber="93" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
 
</td>
<td class="diff-line-num new new_line" data-linenumber="94" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
94
</td>
<td class="line_content new noteable_line" style="background: #ecfdf0; padding-left: 0.5em; padding-right: 0.5em" bgcolor="#ecfdf0">
<pre style="margin: 0">+<span id="LC94" class="line">        <span class="n" style="color: #333">f</span> <span class="o" style="font-weight: bold">=</span> <span class="n" style="color: #333">ntp</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">util</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">unitformatter</span></span>
</pre>
</td>
</tr>
<tr class="line_holder new" id="" style="line-height: 1.6">
<td class="diff-line-num new old_line" data-linenumber="93" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
 
</td>
<td class="diff-line-num new new_line" data-linenumber="95" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
95
</td>
<td class="line_content new noteable_line" style="background: #ecfdf0; padding-left: 0.5em; padding-right: 0.5em" bgcolor="#ecfdf0">
<pre style="margin: 0">+<span id="LC95" class="line">        <span class="n" style="color: #333">usec</span> <span class="o" style="font-weight: bold">=</span> <span class="n" style="color: #333">ntp</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">util</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">UNITS_SEC</span></span>
</pre>
</td>
</tr>
<tr class="line_holder new" id="" style="line-height: 1.6">
<td class="diff-line-num new old_line" data-linenumber="93" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
 
</td>
<td class="diff-line-num new new_line" data-linenumber="96" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
96
</td>
<td class="line_content new noteable_line" style="background: #ecfdf0; padding-left: 0.5em; padding-right: 0.5em" bgcolor="#ecfdf0">
<pre style="margin: 0">+<span id="LC96" class="line">        <span class="bp" style="color: #999">self</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">assertEqual</span><span class="p">(</span><span class="n" style="color: #333">f</span><span class="p">(</span><span class="mf" style="color: #099">0.0000000005</span><span class="p">,</span> <span class="n" style="color: #333">usec</span><span class="p">,</span> <span class="n" style="color: #333">ntp</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">util</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">UNIT_MS</span><span class="p">),</span></span>
</pre>
</td>
</tr>
<tr class="line_holder new" id="" style="line-height: 1.6">
<td class="diff-line-num new old_line" data-linenumber="93" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
 
</td>
<td class="diff-line-num new new_line" data-linenumber="97" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
97
</td>
<td class="line_content new noteable_line" style="background: #ecfdf0; padding-left: 0.5em; padding-right: 0.5em" bgcolor="#ecfdf0">
<pre style="margin: 0">+<span id="LC97" class="line">                         <span class="s" style="color: #d14">"     0ns"</span><span class="p">)</span>  <span class="c" style="color: #998; font-style: italic"># Checking timefuzz</span></span>
</pre>
</td>
</tr>
<tr class="line_holder new" id="" style="line-height: 1.6">
<td class="diff-line-num new old_line" data-linenumber="93" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
 
</td>
<td class="diff-line-num new new_line" data-linenumber="98" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
98
</td>
<td class="line_content new noteable_line" style="background: #ecfdf0; padding-left: 0.5em; padding-right: 0.5em" bgcolor="#ecfdf0">
<pre style="margin: 0">+<span id="LC98" class="line">        <span class="bp" style="color: #999">self</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">assertEqual</span><span class="p">(</span><span class="n" style="color: #333">f</span><span class="p">(</span><span class="mf" style="color: #099">0.0000000005</span><span class="p">,</span> <span class="n" style="color: #333">usec</span><span class="p">,</span> <span class="n" style="color: #333">ntp</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">util</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">UNIT_MS</span><span class="p">,</span> <span class="n" style="color: #333">strip</span><span class="o" style="font-weight: bold">=</span><span class="bp" style="color: #999">True</span><span class="p">),</span></span>
</pre>
</td>
</tr>
<tr class="line_holder new" id="" style="line-height: 1.6">
<td class="diff-line-num new old_line" data-linenumber="93" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
 
</td>
<td class="diff-line-num new new_line" data-linenumber="99" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
99
</td>
<td class="line_content new noteable_line" style="background: #ecfdf0; padding-left: 0.5em; padding-right: 0.5em" bgcolor="#ecfdf0">
<pre style="margin: 0">+<span id="LC99" class="line">                         <span class="s" style="color: #d14">"0ns"</span><span class="p">)</span>  <span class="c" style="color: #998; font-style: italic"># Checking timefuzz, strip</span></span>
</pre>
</td>
</tr>
<tr class="line_holder new" id="" style="line-height: 1.6">
<td class="diff-line-num new old_line" data-linenumber="93" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
 
</td>
<td class="diff-line-num new new_line" data-linenumber="100" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
100
</td>
<td class="line_content new noteable_line" style="background: #ecfdf0; padding-left: 0.5em; padding-right: 0.5em" bgcolor="#ecfdf0">
<pre style="margin: 0">+<span id="LC100" class="line">        <span class="bp" style="color: #999">self</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">assertEqual</span><span class="p">(</span><span class="n" style="color: #333">f</span><span class="p">(</span><span class="mf" style="color: #099">12.45</span><span class="p">,</span> <span class="n" style="color: #333">usec</span><span class="p">,</span> <span class="n" style="color: #333">ntp</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">util</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">UNIT_MS</span><span class="p">),</span></span>
</pre>
</td>
</tr>
<tr class="line_holder new" id="" style="line-height: 1.6">
<td class="diff-line-num new old_line" data-linenumber="93" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
 
</td>
<td class="diff-line-num new new_line" data-linenumber="101" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
101
</td>
<td class="line_content new noteable_line" style="background: #ecfdf0; padding-left: 0.5em; padding-right: 0.5em" bgcolor="#ecfdf0">
<pre style="margin: 0">+<span id="LC101" class="line">                         <span class="s" style="color: #d14">" 12.45ms"</span><span class="p">)</span>  <span class="c" style="color: #998; font-style: italic"># Checking normal</span></span>
</pre>
</td>
</tr>
<tr class="line_holder new" id="" style="line-height: 1.6">
<td class="diff-line-num new old_line" data-linenumber="93" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
 
</td>
<td class="diff-line-num new new_line" data-linenumber="102" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
102
</td>
<td class="line_content new noteable_line" style="background: #ecfdf0; padding-left: 0.5em; padding-right: 0.5em" bgcolor="#ecfdf0">
<pre style="margin: 0">+<span id="LC102" class="line">        <span class="bp" style="color: #999">self</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">assertEqual</span><span class="p">(</span><span class="n" style="color: #333">f</span><span class="p">(</span><span class="mf" style="color: #099">12.45</span><span class="p">,</span> <span class="n" style="color: #333">usec</span><span class="p">,</span> <span class="n" style="color: #333">ntp</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">util</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">UNIT_MS</span><span class="p">,</span> <span class="n" style="color: #333">strip</span><span class="o" style="font-weight: bold">=</span><span class="bp" style="color: #999">True</span><span class="p">),</span></span>
</pre>
</td>
</tr>
<tr class="line_holder new" id="" style="line-height: 1.6">
<td class="diff-line-num new old_line" data-linenumber="93" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
 
</td>
<td class="diff-line-num new new_line" data-linenumber="103" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
103
</td>
<td class="line_content new noteable_line" style="background: #ecfdf0; padding-left: 0.5em; padding-right: 0.5em" bgcolor="#ecfdf0">
<pre style="margin: 0">+<span id="LC103" class="line">                         <span class="s" style="color: #d14">"12.45ms"</span><span class="p">)</span>  <span class="c" style="color: #998; font-style: italic"># Checking normal, strip</span></span>
</pre>
</td>
</tr>
<tr class="line_holder new" id="" style="line-height: 1.6">
<td class="diff-line-num new old_line" data-linenumber="93" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
 
</td>
<td class="diff-line-num new new_line" data-linenumber="104" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
104
</td>
<td class="line_content new noteable_line" style="background: #ecfdf0; padding-left: 0.5em; padding-right: 0.5em" bgcolor="#ecfdf0">
<pre style="margin: 0">+<span id="LC104" class="line">        <span class="bp" style="color: #999">self</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">assertEqual</span><span class="p">(</span><span class="n" style="color: #333">f</span><span class="p">(</span><span class="mf" style="color: #099">123456789.1234</span><span class="p">,</span> <span class="n" style="color: #333">usec</span><span class="p">,</span> <span class="n" style="color: #333">ntp</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">util</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">UNIT_MS</span><span class="p">,</span> <span class="n" style="color: #333">width</span><span class="o" style="font-weight: bold">=</span><span class="bp" style="color: #999">None</span><span class="p">),</span></span>
</pre>
</td>
</tr>
<tr class="line_holder new" id="" style="line-height: 1.6">
<td class="diff-line-num new old_line" data-linenumber="93" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
 
</td>
<td class="diff-line-num new new_line" data-linenumber="105" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
105
</td>
<td class="line_content new noteable_line" style="background: #ecfdf0; padding-left: 0.5em; padding-right: 0.5em" bgcolor="#ecfdf0">
<pre style="margin: 0">+<span id="LC105" class="line">                         <span class="s" style="color: #d14">"123.4567891234ks"</span><span class="p">)</span>  <span class="c" style="color: #998; font-style: italic"># Checking normal, no width</span></span>
</pre>
</td>
</tr>
<tr class="line_holder new" id="" style="line-height: 1.6">
<td class="diff-line-num new old_line" data-linenumber="93" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
 
</td>
<td class="diff-line-num new new_line" data-linenumber="106" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
106
</td>
<td class="line_content new noteable_line" style="background: #ecfdf0; padding-left: 0.5em; padding-right: 0.5em" bgcolor="#ecfdf0">
<pre style="margin: 0">+<span id="LC106" class="line">        <span class="bp" style="color: #999">self</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">assertEqual</span><span class="p">(</span><span class="n" style="color: #333">f</span><span class="p">(</span><span class="mf" style="color: #099">0.000005</span><span class="p">,</span> <span class="n" style="color: #333">usec</span><span class="p">,</span> <span class="n" style="color: #333">ntp</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">util</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">UNIT_MS</span><span class="p">),</span></span>
</pre>
</td>
</tr>
<tr class="line_holder new" id="" style="line-height: 1.6">
<td class="diff-line-num new old_line" data-linenumber="93" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
 
</td>
<td class="diff-line-num new new_line" data-linenumber="107" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
107
</td>
<td class="line_content new noteable_line" style="background: #ecfdf0; padding-left: 0.5em; padding-right: 0.5em" bgcolor="#ecfdf0">
<pre style="margin: 0">+<span id="LC107" class="line">                         <span class="s" style="color: #d14">"     5ns"</span><span class="p">)</span>  <span class="c" style="color: #998; font-style: italic"># Unit == base</span></span>
</pre>
</td>
</tr>
<tr class="line_holder new" id="" style="line-height: 1.6">
<td class="diff-line-num new old_line" data-linenumber="93" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
 
</td>
<td class="diff-line-num new new_line" data-linenumber="108" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
108
</td>
<td class="line_content new noteable_line" style="background: #ecfdf0; padding-left: 0.5em; padding-right: 0.5em" bgcolor="#ecfdf0">
<pre style="margin: 0">+<span id="LC108" class="line">        <span class="bp" style="color: #999">self</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">assertEqual</span><span class="p">(</span><span class="n" style="color: #333">f</span><span class="p">(</span><span class="mf" style="color: #099">0.000005</span><span class="p">,</span> <span class="n" style="color: #333">usec</span><span class="p">,</span> <span class="n" style="color: #333">ntp</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">util</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">UNIT_MS</span><span class="p">,</span> <span class="n" style="color: #333">strip</span><span class="o" style="font-weight: bold">=</span><span class="bp" style="color: #999">True</span><span class="p">),</span></span>
</pre>
</td>
</tr>
<tr class="line_holder new" id="" style="line-height: 1.6">
<td class="diff-line-num new old_line" data-linenumber="93" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
 
</td>
<td class="diff-line-num new new_line" data-linenumber="109" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
109
</td>
<td class="line_content new noteable_line" style="background: #ecfdf0; padding-left: 0.5em; padding-right: 0.5em" bgcolor="#ecfdf0">
<pre style="margin: 0">+<span id="LC109" class="line">                         <span class="s" style="color: #d14">"5ns"</span><span class="p">)</span>  <span class="c" style="color: #998; font-style: italic"># Unit == base, strip</span></span>
</pre>
</td>
</tr>
<tr class="line_holder new" id="" style="line-height: 1.6">
<td class="diff-line-num new old_line" data-linenumber="93" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
 
</td>
<td class="diff-line-num new new_line" data-linenumber="110" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
110
</td>
<td class="line_content new noteable_line" style="background: #ecfdf0; padding-left: 0.5em; padding-right: 0.5em" bgcolor="#ecfdf0">
<pre style="margin: 0">+<span id="LC110" class="line">        <span class="bp" style="color: #999">self</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">assertEqual</span><span class="p">(</span><span class="n" style="color: #333">f</span><span class="p">(</span><span class="mf" style="color: #099">0.000005</span><span class="p">,</span> <span class="n" style="color: #333">usec</span><span class="p">,</span> <span class="n" style="color: #333">ntp</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">util</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">UNIT_MS</span><span class="p">,</span> <span class="n" style="color: #333">width</span><span class="o" style="font-weight: bold">=</span><span class="bp" style="color: #999">None</span><span class="p">),</span></span>
</pre>
</td>
</tr>
<tr class="line_holder new" id="" style="line-height: 1.6">
<td class="diff-line-num new old_line" data-linenumber="93" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
 
</td>
<td class="diff-line-num new new_line" data-linenumber="111" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
111
</td>
<td class="line_content new noteable_line" style="background: #ecfdf0; padding-left: 0.5em; padding-right: 0.5em" bgcolor="#ecfdf0">
<pre style="margin: 0">+<span id="LC111" class="line">                         <span class="s" style="color: #d14">"5ns"</span><span class="p">)</span>  <span class="c" style="color: #998; font-style: italic"># Unit == base, no width</span></span>
</pre>
</td>
</tr>
<tr class="line_holder new" id="" style="line-height: 1.6">
<td class="diff-line-num new old_line" data-linenumber="93" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
 
</td>
<td class="diff-line-num new new_line" data-linenumber="112" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
112
</td>
<td class="line_content new noteable_line" style="background: #ecfdf0; padding-left: 0.5em; padding-right: 0.5em" bgcolor="#ecfdf0">
<pre style="margin: 0">+<span id="LC112" class="line">        <span class="bp" style="color: #999">self</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">assertEqual</span><span class="p">(</span><span class="n" style="color: #333">f</span><span class="p">(</span><span class="mf" style="color: #099">10000.1</span><span class="p">,</span> <span class="n" style="color: #333">usec</span><span class="p">,</span> <span class="n" style="color: #333">ntp</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">util</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">UNIT_KS</span><span class="p">),</span></span>
</pre>
</td>
</tr>
<tr class="line_holder new" id="" style="line-height: 1.6">
<td class="diff-line-num new old_line" data-linenumber="93" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
 
</td>
<td class="diff-line-num new new_line" data-linenumber="113" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
113
</td>
<td class="line_content new noteable_line" style="background: #ecfdf0; padding-left: 0.5em; padding-right: 0.5em" bgcolor="#ecfdf0">
<pre style="margin: 0">+<span id="LC113" class="line">                         <span class="s" style="color: #d14">"10000.1ks"</span><span class="p">)</span>  <span class="c" style="color: #998; font-style: italic"># Value outside of unit ranges</span></span>
</pre>
</td>
</tr>
<tr class="line_holder new" id="" style="line-height: 1.6">
<td class="diff-line-num new old_line" data-linenumber="93" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
 
</td>
<td class="diff-line-num new new_line" data-linenumber="114" style="background: #ddfbe6; border-right-color: #c7f0d2; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#ddfbe6">
114
</td>
<td class="line_content new noteable_line" style="background: #ecfdf0; padding-left: 0.5em; padding-right: 0.5em" bgcolor="#ecfdf0">
<pre style="margin: 0">+<span id="LC114" class="line"></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6">
<td class="diff-line-num old_line" data-linenumber="93" style="background: #fafafa; border-right-color: #f0f0f0; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#fafafa">
93
</td>
<td class="diff-line-num new_line" data-linenumber="115" style="background: #fafafa; border-right-color: #f0f0f0; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#fafafa">
115
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em">
<pre style="margin: 0"> <span id="LC115" class="line"><span class="k" style="font-weight: bold">if</span> <span class="n" style="color: #333">__name__</span> <span class="o" style="font-weight: bold">==</span> <span class="s" style="color: #d14">'__main__'</span><span class="p">:</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6">
<td class="diff-line-num old_line" data-linenumber="94" style="background: #fafafa; border-right-color: #f0f0f0; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#fafafa">
94
</td>
<td class="diff-line-num new_line" data-linenumber="116" style="background: #fafafa; border-right-color: #f0f0f0; border-right-style: solid; border-right-width: 1px; color: rgba(0,0,0,0.3); padding: 0 5px; text-align: right; width: 35px" align="right" bgcolor="#fafafa">
116
</td>
<td class="line_content noteable_line" style="padding-left: 0.5em; padding-right: 0.5em">
<pre style="margin: 0"> <span id="LC116" class="line">    <span class="n" style="color: #333">unittest</span><span class="o" style="font-weight: bold">.</span><span class="n" style="color: #333">main</span><span class="p">()</span></span></pre>
</td>
</tr>

</table>
<br>
</li>

</div>
<div class="footer" style="margin-top: 10px">
<p style="color: #777; font-size: small">

<br>
<a href="https://gitlab.com/NTPsec/ntpsec/commit/ccc00e16bb0e2e3376cc7b19f22b844746669682">View it on GitLab</a>.
<br>
You're receiving this email because of your account on gitlab.com.
If you'd like to receive fewer emails, you can
adjust your notification settings.
<script type="application/ld+json">{"@context":"http://schema.org","@type":"EmailMessage","action":{"@type":"ViewAction","name":"View Commit","url":"https://gitlab.com/NTPsec/ntpsec/commit/ccc00e16bb0e2e3376cc7b19f22b844746669682"}}</script>
</p>
</div>
</body>
</html>