[Git][NTPsec/ntpsec][master] Fix failed tests in ntpd/leapsec.c.
Amar Takhar
gitlab at mg.gitlab.com
Fri Dec 4 21:35:45 UTC 2015
Amar Takhar pushed to branch master at NTPsec / ntpsec
Commits:
3e947309 by Amar Takhar at 2015-12-04T16:35:24Z
Fix failed tests in ntpd/leapsec.c.
- - - - -
2 changed files:
- tests/ntpd/leapsec.c
- tests/wscript
Changes:
=====================================
tests/ntpd/leapsec.c
=====================================
--- a/tests/ntpd/leapsec.c
+++ b/tests/ntpd/leapsec.c
@@ -445,7 +445,7 @@ TEST(leapsec, ls2009faraway) {
bool rc;
leap_result_t qr;
- rc = setup_load_table(leap1, 1);
+ rc = setup_load_table(leap1, 0);
TEST_ASSERT_EQUAL(1, rc);
// test 60 days before leap. Nothing scheduled or indicated.
@@ -462,7 +462,7 @@ TEST(leapsec, ls2009weekaway) {
bool rc;
leap_result_t qr;
- rc = setup_load_table(leap1, 1);
+ rc = setup_load_table(leap1, 0);
TEST_ASSERT_EQUAL(1, rc);
// test 7 days before leap. Leap scheduled, but not yet indicated.
@@ -479,7 +479,7 @@ TEST(leapsec, ls2009houraway) {
bool rc;
leap_result_t qr;
- rc = setup_load_table(leap1, 1);
+ rc = setup_load_table(leap1, 0);
TEST_ASSERT_EQUAL(1, rc);
// test 1 hour before leap. 61 true seconds to go.
@@ -496,7 +496,7 @@ TEST(leapsec, ls2009secaway) {
bool rc;
leap_result_t qr;
- rc = setup_load_table(leap1, 1);
+ rc = setup_load_table(leap1, 0);
TEST_ASSERT_TRUE(rc);
// test 1 second before leap (last boundary...) 2 true seconds to go.
@@ -513,7 +513,7 @@ TEST(leapsec, ls2009onspot) {
bool rc;
leap_result_t qr;
- rc = setup_load_table(leap1, 1);
+ rc = setup_load_table(leap1, 0);
TEST_ASSERT_TRUE(rc);
// test on-spot: treat leap second as already gone.
@@ -644,7 +644,7 @@ TEST(leapsec, ls2009seqInsElectric) {
bool rc;
leap_result_t qr;
- rc = setup_load_table(leap1, 1);
+ rc = setup_load_table(leap1, 0);
TEST_ASSERT_TRUE(rc);
leapsec_electric(1);
TEST_ASSERT_TRUE(leapsec_electric(-1));
@@ -687,7 +687,7 @@ TEST(leapsec, ls2009seqInsDumb) {
bool rc;
leap_result_t qr;
- rc = setup_load_table(leap1, 1);
+ rc = setup_load_table(leap1, 0);
TEST_ASSERT_TRUE(rc);
TEST_ASSERT_EQUAL(0, leapsec_electric(-1));
@@ -735,7 +735,7 @@ TEST(leapsec, ls2009seqDelElectric) {
bool rc;
leap_result_t qr;
- rc = setup_load_table(leap3, 1);
+ rc = setup_load_table(leap3, 0);
TEST_ASSERT_TRUE(rc);
leapsec_electric(1);
TEST_ASSERT_TRUE(leapsec_electric(-1));
@@ -778,7 +778,7 @@ TEST(leapsec, ls2009seqDelDumb) {
bool rc;
leap_result_t qr;
- rc = setup_load_table(leap3, 1);
+ rc = setup_load_table(leap3, 0);
TEST_ASSERT_TRUE(rc);
TEST_ASSERT_EQUAL(0, leapsec_electric(-1));
@@ -820,7 +820,7 @@ TEST(leapsec, ls2012seqInsElectric) {
bool rc;
leap_result_t qr;
- rc = setup_load_table(leap1, 1);
+ rc = setup_load_table(leap1, 0);
TEST_ASSERT_TRUE(rc);
leapsec_electric(1);
TEST_ASSERT_TRUE(leapsec_electric(-1));
@@ -863,7 +863,7 @@ TEST(leapsec, ls2012seqInsDumb) {
bool rc;
leap_result_t qr;
- rc = setup_load_table(leap1, 1);
+ rc = setup_load_table(leap1, 0);
TEST_ASSERT_TRUE(rc);
TEST_ASSERT_EQUAL(0, leapsec_electric(-1));
=====================================
tests/wscript
=====================================
--- a/tests/wscript
+++ b/tests/wscript
@@ -104,10 +104,9 @@ def build(ctx):
)
-"""
ntpd_source = [
"ntpd/leapsec.c"
- ] + common_source + ["common/caltime.c"]
+ ] + common_source
ctx.ntp_test(
features = "c cprogram bld_include src_include libisc_include test",
@@ -122,4 +121,3 @@ def build(ctx):
use = "ntpd_lib libntpd_obj unity ntp isc M PTHREAD CRYPTO RT",
source = ntpd_source,
)
-"""
View it on GitLab: https://gitlab.com/NTPsec/ntpsec/commit/3e94730968c369761724f819b349b3b451e8f132
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.ntpsec.org/pipermail/vc/attachments/20151204/ac79fa5a/attachment.html>
More information about the vc
mailing list