You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kudu.apache.org by al...@apache.org on 2019/11/20 18:34:38 UTC

[kudu] branch master updated: [clock] run TestNtpDiagnostics against chrony as well

This is an automated email from the ASF dual-hosted git repository.

alexey pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/kudu.git


View the commit online:
https://github.com/apache/kudu/commit/80e28503be8391cae07e77e616c576a01386581d

The following commit(s) were added to refs/heads/master by this push:
     new 80e2850  [clock] run TestNtpDiagnostics against chrony as well
80e2850 is described below

commit 80e28503be8391cae07e77e616c576a01386581d
Author: Alexey Serbin <al...@apache.org>
AuthorDate: Tue Nov 19 21:29:16 2019 -0800

    [clock] run TestNtpDiagnostics against chrony as well
    
    This patch updates the HybridClockTest.TestNtpDiagnostics scenario to
    successfully run at machines where 'chronyd' is used as the system
    NTP daemon (i.e. rely on the utility suite from the 'chrony' package).
    Prior to this patch, the scenario was able to run only against machines
    with 'ntpd' as the system daemon (i.e. relied on the utility suite from
    the 'ntp' package).
    
    Change-Id: If9c14e939c2722304ce6c5a9f7fc812af183b353
    Reviewed-on: http://gerrit.cloudera.org:8080/14751
    Reviewed-by: Adar Dembo <ad...@cloudera.com>
    Tested-by: Kudu Jenkins
---
 src/kudu/clock/hybrid_clock-test.cc | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/kudu/clock/hybrid_clock-test.cc b/src/kudu/clock/hybrid_clock-test.cc
index a427b8e..09505e7 100644
--- a/src/kudu/clock/hybrid_clock-test.cc
+++ b/src/kudu/clock/hybrid_clock-test.cc
@@ -357,8 +357,8 @@ TEST_F(HybridClockTest, TestNtpDiagnostics) {
   clock_->time_service()->DumpDiagnostics(&log);
   string s = JoinStrings(log, "\n");
   SCOPED_TRACE(s);
-  ASSERT_STR_CONTAINS(s, "ntpq");
-  ASSERT_STR_CONTAINS(s, "ntp_gettime");
+  ASSERT_STR_MATCHES(s, "(ntp_gettime\\(\\) returns code |chronyc -n tracking)");
+  ASSERT_STR_MATCHES(s, "(ntpq -n |chronyc -n sources)");
 }
 #endif