From cf56526f97de3dfcc3a1a869350acf3aca07b7a1 Mon Sep 17 00:00:00 2001 From: Paulo Truta Date: Sat, 12 Jun 2021 14:32:41 +0000 Subject: [PATCH] Added branch to test for valid key in GetPath --- internal/utils/utils_test.go | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/internal/utils/utils_test.go b/internal/utils/utils_test.go index 840985d..098396b 100644 --- a/internal/utils/utils_test.go +++ b/internal/utils/utils_test.go @@ -86,6 +86,13 @@ func TestGetPath(t *testing.T) { if result != "" { t.Log("Expected empty result but got ", result) } + + validPathKey := "wsPath" + result = GetPath(validPathKey) + if result != "/home/system/components/ws/" { + t.Log("Expected /home/system/components/ws/ but got", result) + t.Fail() + } } func TestGetSQLiteFormattedDateTime(t *testing.T) {