From 3a37f845e4f3a8cd1452eb59c2620beba280f032 Mon Sep 17 00:00:00 2001 From: Daniel Bacher Date: Mon, 9 Nov 2020 16:02:46 +0100 Subject: [PATCH] add test case get_ntp_server for SG500-28-K9 closes #38 --- .../SG500-28-K9/show_sntp_status.txt | 32 +++++++++++++ .../SG500-28-K9/expected_result.json | 6 +++ .../SG500-28-K9/show_sntp_status.txt | 45 +++++++++++++++++++ 3 files changed, 83 insertions(+) create mode 100644 test/unit/mocked_data/test_get_ntp_servers/SG500-28-K9/expected_result.json create mode 100644 test/unit/mocked_data/test_get_ntp_servers/SG500-28-K9/show_sntp_status.txt diff --git a/test/unit/mocked_data/SG500-28-K9/show_sntp_status.txt b/test/unit/mocked_data/SG500-28-K9/show_sntp_status.txt index 6b90b23..d20a417 100644 --- a/test/unit/mocked_data/SG500-28-K9/show_sntp_status.txt +++ b/test/unit/mocked_data/SG500-28-K9/show_sntp_status.txt @@ -3,6 +3,38 @@ Clock is unsynchronized Unicast servers: +Server : 192.168.186.1 + Source : Static + Stratum : 255 + Status : unknown + Last Response : 00:00:00.0 Jan 1 1900 + Offset : 0.0000000 mSec + Delay : 0 mSec + +Server : 192.168.186.2 + Source : Static + Stratum : 255 + Status : unknown + Last Response : 00:00:00.0 Jan 1 1900 + Offset : 0.0000000 mSec + Delay : 0 mSec + +Server : 192.168.186.3 + Source : Static + Stratum : 255 + Status : unknown + Last Response : 00:00:00.0 Jan 1 1900 + Offset : 0.0000000 mSec + Delay : 0 mSec + +Server : 192.168.186.4 + Source : Static + Stratum : 255 + Status : unknown + Last Response : 00:00:00.0 Jan 1 1900 + Offset : 0.0000000 mSec + Delay : 0 mSec + Anycast server: diff --git a/test/unit/mocked_data/test_get_ntp_servers/SG500-28-K9/expected_result.json b/test/unit/mocked_data/test_get_ntp_servers/SG500-28-K9/expected_result.json new file mode 100644 index 0000000..f646fec --- /dev/null +++ b/test/unit/mocked_data/test_get_ntp_servers/SG500-28-K9/expected_result.json @@ -0,0 +1,6 @@ +{ + "192.168.186.1": {}, + "192.168.186.2": {}, + "192.168.186.3": {}, + "192.168.186.4": {} +} diff --git a/test/unit/mocked_data/test_get_ntp_servers/SG500-28-K9/show_sntp_status.txt b/test/unit/mocked_data/test_get_ntp_servers/SG500-28-K9/show_sntp_status.txt new file mode 100644 index 0000000..d20a417 --- /dev/null +++ b/test/unit/mocked_data/test_get_ntp_servers/SG500-28-K9/show_sntp_status.txt @@ -0,0 +1,45 @@ + +Clock is unsynchronized + +Unicast servers: + +Server : 192.168.186.1 + Source : Static + Stratum : 255 + Status : unknown + Last Response : 00:00:00.0 Jan 1 1900 + Offset : 0.0000000 mSec + Delay : 0 mSec + +Server : 192.168.186.2 + Source : Static + Stratum : 255 + Status : unknown + Last Response : 00:00:00.0 Jan 1 1900 + Offset : 0.0000000 mSec + Delay : 0 mSec + +Server : 192.168.186.3 + Source : Static + Stratum : 255 + Status : unknown + Last Response : 00:00:00.0 Jan 1 1900 + Offset : 0.0000000 mSec + Delay : 0 mSec + +Server : 192.168.186.4 + Source : Static + Stratum : 255 + Status : unknown + Last Response : 00:00:00.0 Jan 1 1900 + Offset : 0.0000000 mSec + Delay : 0 mSec + + + +Anycast server: + + + +Broadcast: +