From d7e498caf9b3b1966a4e9102b0365b88bff2b3cb Mon Sep 17 00:00:00 2001 From: Andrea Terzolo Date: Thu, 9 Feb 2023 15:43:24 +0100 Subject: [PATCH] fix after rebase Signed-off-by: Andrea Terzolo --- unit_tests/README.md | 3 ++- unit_tests/falco/test_configuration.cpp | 11 +++++------ 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/unit_tests/README.md b/unit_tests/README.md index 0e6284e6..93373d70 100644 --- a/unit_tests/README.md +++ b/unit_tests/README.md @@ -8,5 +8,6 @@ Under `unit_tests/engine` and `unit_tests/falco` directories, we have different ```bash cmake -DMINIMAL_BUILD=On -DBUILD_BPF=Off -DBUILD_DRIVER=Off -DBUILD_FALCO_UNIT_TESTS=On .. -make falco_unit_tests +make falco_unit_tests +sudo ./unit_tests/falco_unit_tests ``` diff --git a/unit_tests/falco/test_configuration.cpp b/unit_tests/falco/test_configuration.cpp index 2b79371e..1088ae9e 100644 --- a/unit_tests/falco/test_configuration.cpp +++ b/unit_tests/falco/test_configuration.cpp @@ -17,8 +17,7 @@ limitations under the License. #include #include - -static std:: string sample_yaml = +static std::string sample_yaml = "base_value:\n" " id: 1\n" " name: 'sample_name'\n" @@ -33,7 +32,7 @@ static std:: string sample_yaml = TEST(Configuration, configuration_exceptions) { - yaml_configuration conf; + yaml_helper conf; /* Broken YAML */ string sample_broken_yaml = sample_yaml + " / bad_symbol"; @@ -45,7 +44,7 @@ TEST(Configuration, configuration_exceptions) TEST(Configuration, configuration_reload) { - yaml_configuration conf; + yaml_helper conf; /* Clear and reload config */ conf.load_from_string(sample_yaml); @@ -58,7 +57,7 @@ TEST(Configuration, configuration_reload) TEST(Configuration, read_yaml_fields) { - yaml_configuration conf; + yaml_helper conf; conf.load_from_string(sample_yaml); /* is_defined */ @@ -88,7 +87,7 @@ TEST(Configuration, read_yaml_fields) TEST(Configuration, modify_yaml_fields) { string key = "base_value.subvalue.subvalue2.boolean"; - yaml_configuration conf; + yaml_helper conf; /* Get original value */ conf.load_from_string(sample_yaml);