add json config and implementation for hysteresis

Add the json config for health metric hysteresis and implementation
logic for it. Update the health metric config test to validate the
hysteresis value.

Change-Id: I60c0daa601abee9ac1916581d23257cc04128dd0
Signed-off-by: Jagpal Singh Gill <paligill@gmail.com>
diff --git a/health_metric_config.hpp b/health_metric_config.hpp
index 5943878..89fecdc 100644
--- a/health_metric_config.hpp
+++ b/health_metric_config.hpp
@@ -73,6 +73,8 @@
     SubType subType = SubType::NA;
     /** @brief The window size for the metric. */
     size_t windowSize = defaults::windowSize;
+    /** @brief The hysteresis for the metric */
+    double hysteresis = defaults::hysteresis;
     /** @brief The threshold configs for the metric. */
     Threshold::map_t thresholds{};
     /** @brief The path for filesystem metric */
@@ -84,6 +86,7 @@
     {
         static constexpr auto windowSize = 1;
         static constexpr auto path = "";
+        static constexpr auto hysteresis = 1.0;
     };
 };