From 20da8873dc95fd72d8924357c6e92c2319ecdcb4 Mon Sep 17 00:00:00 2001 From: Akash Chandra Date: Mon, 28 Oct 2024 19:31:58 +0530 Subject: [PATCH] fix: Added Test Case for Info Compare verification --- cmd/diff_test.go | 5 +++ .../all_flash_cluster_cr_info_cap.conf | 44 +++++++++++++++++++ 2 files changed, 49 insertions(+) create mode 100644 testdata/expected/all_flash_cluster_cr_info_cap.conf diff --git a/cmd/diff_test.go b/cmd/diff_test.go index 355ca5b..e1fb3dc 100644 --- a/cmd/diff_test.go +++ b/cmd/diff_test.go @@ -68,6 +68,11 @@ var testDiffArgs = []runTestDiff{ arguments: []string{}, expectError: true, }, + { + flags: []string{"--log-level", "debug"}, + arguments: []string{"../testdata/expected/all_flash_cluster_cr.conf", "../testdata/expected/all_flash_cluster_cr_info_cap.conf"}, + expectError: false, + }, } func TestRunEDiff(t *testing.T) { diff --git a/testdata/expected/all_flash_cluster_cr_info_cap.conf b/testdata/expected/all_flash_cluster_cr_info_cap.conf new file mode 100644 index 0000000..c7bc647 --- /dev/null +++ b/testdata/expected/all_flash_cluster_cr_info_cap.conf @@ -0,0 +1,44 @@ + +logging { + + console { + context any INFO + } +} + +namespace test { + memory-size 3000000000 + replication-factor 2 + + index-type flash { + mount /test/dev/xvdf-index + mounts-size-limit 4294967296 + } + + storage-engine device { + device /test/dev/xvdf + } +} + +network { + + fabric { + port 3001 + } + + heartbeat { + mode mesh + port 3002 + } + + service { + port 3000 + } +} + +security { +} + +service { + feature-key-file /etc/aerospike/secret/features.conf +}