diff --git a/src/discrete_threshold.cpp b/src/discrete_threshold.cpp
index 9195878..0d98c28 100644
--- a/src/discrete_threshold.cpp
+++ b/src/discrete_threshold.cpp
@@ -12,8 +12,7 @@
     Milliseconds dwellTimeIn, const std::string& thresholdValueIn,
     const std::string& nameIn, const discrete::Severity severityIn,
     std::unique_ptr<interfaces::Clock> clockIn) :
-    ioc(ioc),
-    triggerId(triggerIdIn), actions(std::move(actionsIn)),
+    ioc(ioc), triggerId(triggerIdIn), actions(std::move(actionsIn)),
     dwellTime(dwellTimeIn), thresholdValue(thresholdValueIn),
     numericThresholdValue(utils::stodStrict(thresholdValue)),
     severity(severityIn), name(getNonEmptyName(nameIn)),
diff --git a/src/discrete_threshold.hpp b/src/discrete_threshold.hpp
index 3b0d101..1284461 100644
--- a/src/discrete_threshold.hpp
+++ b/src/discrete_threshold.hpp
@@ -56,8 +56,7 @@
 
         ThresholdDetail(const std::string& sensorNameIn,
                         boost::asio::io_context& ioc) :
-            timer(ioc),
-            sensorName(sensorNameIn)
+            timer(ioc), sensorName(sensorNameIn)
         {}
         ThresholdDetail(const ThresholdDetail&) = delete;
         ThresholdDetail(ThresholdDetail&&) = delete;
diff --git a/src/interfaces/sensor.hpp b/src/interfaces/sensor.hpp
index 7764b37..78a762e 100644
--- a/src/interfaces/sensor.hpp
+++ b/src/interfaces/sensor.hpp
@@ -21,9 +21,7 @@
     struct Id
     {
         Id(std::string_view type, std::string_view service,
-           std::string_view path) :
-            type(type),
-            service(service), path(path)
+           std::string_view path) : type(type), service(service), path(path)
         {}
 
         std::string type;
diff --git a/src/metric.cpp b/src/metric.cpp
index 2504dbf..c1c5fd2 100644
--- a/src/metric.cpp
+++ b/src/metric.cpp
@@ -14,9 +14,8 @@
                CollectionTimeScope timeScopeIn,
                CollectionDuration collectionDurationIn,
                std::unique_ptr<interfaces::Clock> clockIn) :
-    sensors(std::move(sensorsIn)),
-    operationType(operationTypeIn), collectionTimeScope(timeScopeIn),
-    collectionDuration(collectionDurationIn),
+    sensors(std::move(sensorsIn)), operationType(operationTypeIn),
+    collectionTimeScope(timeScopeIn), collectionDuration(collectionDurationIn),
     collectionAlgorithms(
         metrics::makeCollectionData(sensors.size(), operationType,
                                     collectionTimeScope, collectionDuration)),
diff --git a/src/metric_value.hpp b/src/metric_value.hpp
index 5e7c6df..cbf259b 100644
--- a/src/metric_value.hpp
+++ b/src/metric_value.hpp
@@ -11,7 +11,6 @@
 
     MetricValue(std::string_view metadataIn, double valueIn,
                 uint64_t timestampIn) :
-        metadata(metadataIn),
-        value(valueIn), timestamp(timestampIn)
+        metadata(metadataIn), value(valueIn), timestamp(timestampIn)
     {}
 };
diff --git a/src/metrics/collection_data.cpp b/src/metrics/collection_data.cpp
index 3610cba..915f570 100644
--- a/src/metrics/collection_data.cpp
+++ b/src/metrics/collection_data.cpp
@@ -35,8 +35,7 @@
   public:
     DataInterval(std::shared_ptr<CollectionFunction> function,
                  CollectionDuration duration) :
-        function(std::move(function)),
-        duration(duration)
+        function(std::move(function)), duration(duration)
     {
         if (duration.t.count() == 0)
         {
diff --git a/src/numeric_threshold.cpp b/src/numeric_threshold.cpp
index 5980e23..2a02a92 100644
--- a/src/numeric_threshold.cpp
+++ b/src/numeric_threshold.cpp
@@ -9,8 +9,7 @@
     Milliseconds dwellTimeIn, numeric::Direction directionIn,
     double thresholdValueIn, numeric::Type typeIn,
     std::unique_ptr<interfaces::Clock> clockIn) :
-    ioc(ioc),
-    triggerId(triggerIdIn), actions(std::move(actionsIn)),
+    ioc(ioc), triggerId(triggerIdIn), actions(std::move(actionsIn)),
     dwellTime(dwellTimeIn), direction(directionIn),
     thresholdValue(thresholdValueIn), type(typeIn), clock(std::move(clockIn))
 {
diff --git a/src/numeric_threshold.hpp b/src/numeric_threshold.hpp
index 4b861a3..5337624 100644
--- a/src/numeric_threshold.hpp
+++ b/src/numeric_threshold.hpp
@@ -57,8 +57,7 @@
 
         ThresholdDetail(const std::string& sensorNameIn,
                         boost::asio::io_context& ioc) :
-            timer(ioc),
-            sensorName(sensorNameIn)
+            timer(ioc), sensorName(sensorNameIn)
         {}
         ThresholdDetail(const ThresholdDetail&) = delete;
         ThresholdDetail(ThresholdDetail&&) = delete;
diff --git a/src/on_change_threshold.cpp b/src/on_change_threshold.cpp
index 206deb2..b05f4a4 100644
--- a/src/on_change_threshold.cpp
+++ b/src/on_change_threshold.cpp
@@ -6,9 +6,8 @@
     const std::string& triggerIdIn, Sensors sensorsIn,
     std::vector<std::unique_ptr<interfaces::TriggerAction>> actionsIn,
     std::unique_ptr<interfaces::Clock> clockIn) :
-    triggerId(triggerIdIn),
-    sensors(std::move(sensorsIn)), actions(std::move(actionsIn)),
-    clock(std::move(clockIn))
+    triggerId(triggerIdIn), sensors(std::move(sensorsIn)),
+    actions(std::move(actionsIn)), clock(std::move(clockIn))
 {}
 
 void OnChangeThreshold::initialize()
diff --git a/src/report.cpp b/src/report.cpp
index c9df1e2..21302b4 100644
--- a/src/report.cpp
+++ b/src/report.cpp
@@ -31,8 +31,7 @@
                const interfaces::ReportFactory& reportFactory,
                const bool enabledIn, std::unique_ptr<interfaces::Clock> clock,
                Readings readingsIn) :
-    id(reportId),
-    path(utils::pathAppend(utils::constants::reportDirPath, id)),
+    id(reportId), path(utils::pathAppend(utils::constants::reportDirPath, id)),
     name(reportName), reportingType(reportingTypeIn), interval(intervalIn),
     reportActions(reportActionsIn.begin(), reportActionsIn.end()),
     metricCount(getMetricCount(metricsIn)), appendLimit(appendLimitIn),
@@ -203,8 +202,7 @@
             persistency = storeConfiguration();
         }
         return 1;
-    },
-        [this](const auto&) { return state.get<ReportFlags::enabled>(); });
+    }, [this](const auto&) { return state.get<ReportFlags::enabled>(); });
     dbusIface->register_method(
         "SetReportingProperties",
         [this](std::string newReportingType, uint64_t newInterval) {
@@ -276,8 +274,7 @@
             persistency = oldVal = false;
         }
         return 1;
-    },
-        [this](const auto&) { return persistency; });
+    }, [this](const auto&) { return persistency; });
 
     dbusIface->register_property_r("Readings", readings,
                                    sdbusplus::vtable::property_::emits_change,
@@ -302,8 +299,7 @@
         persistency = storeConfiguration();
         oldVal = std::move(newVal);
         return 1;
-    },
-        [this](const auto&) { return readingParameters; });
+    }, [this](const auto&) { return readingParameters; });
     dbusIface->register_property_r<bool>("EmitsReadingsUpdate",
                                          sdbusplus::vtable::property_::none,
                                          [this](const auto&) {
@@ -334,8 +330,7 @@
             oldVal = std::move(newVal);
         }
         return 1;
-    },
-        [this](const auto&) {
+    }, [this](const auto&) {
         return utils::transform<std::vector>(reportActions,
                                              [](const auto reportAction) {
             return utils::enumToString(reportAction);
@@ -344,15 +339,13 @@
     dbusIface->register_property_r<uint64_t>(
         "AppendLimit", sdbusplus::vtable::property_::emits_change,
         [this](const auto&) { return appendLimit; });
-    dbusIface->register_property_rw(
-        "ReportUpdates", std::string(),
-        sdbusplus::vtable::property_::emits_change,
-        [this](auto newVal, auto& oldVal) {
+    dbusIface->register_property_rw("ReportUpdates", std::string(),
+                                    sdbusplus::vtable::property_::emits_change,
+                                    [this](auto newVal, auto& oldVal) {
         setReportUpdates(utils::toReportUpdates(newVal));
         oldVal = newVal;
         return 1;
-    },
-        [this](const auto&) { return utils::enumToString(reportUpdates); });
+    }, [this](const auto&) { return utils::enumToString(reportUpdates); });
     dbusIface->register_property_r(
         "Triggers", std::vector<sdbusplus::message::object_path>{},
         sdbusplus::vtable::property_::emits_change, [this](const auto&) {
diff --git a/src/report_factory.cpp b/src/report_factory.cpp
index 2d7cd40..c798247 100644
--- a/src/report_factory.cpp
+++ b/src/report_factory.cpp
@@ -12,8 +12,7 @@
     std::shared_ptr<sdbusplus::asio::connection> bus,
     const std::shared_ptr<sdbusplus::asio::object_server>& objServer,
     SensorCache& sensorCache) :
-    bus(std::move(bus)),
-    objServer(objServer), sensorCache(sensorCache)
+    bus(std::move(bus)), objServer(objServer), sensorCache(sensorCache)
 {}
 
 std::unique_ptr<interfaces::Report> ReportFactory::make(
diff --git a/src/sensor.cpp b/src/sensor.cpp
index 048dc52..f6f232b 100644
--- a/src/sensor.cpp
+++ b/src/sensor.cpp
@@ -11,8 +11,8 @@
 Sensor::Sensor(interfaces::Sensor::Id sensorId,
                const std::string& sensorMetadata, boost::asio::io_context& ioc,
                const std::shared_ptr<sdbusplus::asio::connection>& bus) :
-    sensorId(std::move(sensorId)),
-    sensorMetadata(sensorMetadata), ioc(ioc), bus(bus)
+    sensorId(std::move(sensorId)), sensorMetadata(sensorMetadata), ioc(ioc),
+    bus(bus)
 {}
 
 Sensor::Id Sensor::makeId(std::string_view service, std::string_view path)
diff --git a/src/trigger.cpp b/src/trigger.cpp
index b80afa7..ca6804c 100644
--- a/src/trigger.cpp
+++ b/src/trigger.cpp
@@ -66,8 +66,7 @@
                 persistent = false;
             }
             return 1;
-        },
-            [this](const auto&) { return persistent; });
+        }, [this](const auto&) { return persistent; });
 
         dbusIface.register_property_rw(
             "Thresholds", TriggerThresholdParams{},
@@ -81,8 +80,7 @@
                                             newThresholdParams);
             oldVal = std::move(newVal);
             return 1;
-        },
-            [this](const auto&) {
+        }, [this](const auto&) {
             return fromLabeledThresholdParam(getLabeledThresholds());
         });
 
@@ -99,8 +97,7 @@
             }
             oldVal = std::move(newVal);
             return 1;
-        },
-            [this](const auto&) {
+        }, [this](const auto&) {
             return utils::fromLabeledSensorsInfo(getLabeledSensorInfo());
         });
 
@@ -117,8 +114,7 @@
                 messages::Presence::Exist, *id, *reportIds});
             oldVal = std::move(newVal);
             return 1;
-        },
-            [this](const auto&) {
+        }, [this](const auto&) {
             return utils::transform<std::vector>(*reportIds,
                                                  [](const auto& id) {
                 return utils::pathAppend(utils::constants::reportDirPath, id);
@@ -138,8 +134,7 @@
             }
             name = oldVal = newVal;
             return 1;
-        },
-            [this](const auto&) { return name; });
+        }, [this](const auto&) { return name; });
 
         dbusIface.register_property_r(
             "TriggerActions", std::vector<std::string>(),
diff --git a/src/trigger_actions.hpp b/src/trigger_actions.hpp
index 3e2c33c..83baca9 100644
--- a/src/trigger_actions.hpp
+++ b/src/trigger_actions.hpp
@@ -136,8 +136,7 @@
   public:
     UpdateReport(boost::asio::io_context& ioc,
                  std::shared_ptr<std::vector<std::string>> ids) :
-        ioc(ioc),
-        reportIds(std::move(ids))
+        ioc(ioc), reportIds(std::move(ids))
     {}
 
     void commit(const std::string& triggerId, const ThresholdName thresholdName,
diff --git a/src/trigger_factory.cpp b/src/trigger_factory.cpp
index 9f91b77..22b7ea5 100644
--- a/src/trigger_factory.cpp
+++ b/src/trigger_factory.cpp
@@ -16,8 +16,8 @@
     std::shared_ptr<sdbusplus::asio::connection> bus,
     std::shared_ptr<sdbusplus::asio::object_server> objServer,
     SensorCache& sensorCache) :
-    bus(std::move(bus)),
-    objServer(std::move(objServer)), sensorCache(sensorCache)
+    bus(std::move(bus)), objServer(std::move(objServer)),
+    sensorCache(sensorCache)
 {}
 
 void TriggerFactory::updateDiscreteThresholds(
diff --git a/src/utils/labeled_tuple.hpp b/src/utils/labeled_tuple.hpp
index c519dd4..062b908 100644
--- a/src/utils/labeled_tuple.hpp
+++ b/src/utils/labeled_tuple.hpp
@@ -205,13 +205,11 @@
 
     bool operator==(const LabeledTuple& other) const
     {
-        return std::apply(
-            [&](auto&&... x) {
-            return std::apply(
-                [&](auto&&... y) { return (true && ... && detail::eq(x, y)); },
-                value);
-        },
-            other.value);
+        return std::apply([&](auto&&... x) {
+            return std::apply([&](auto&&... y) {
+                return (true && ... && detail::eq(x, y));
+            }, value);
+        }, other.value);
     }
 
     bool operator<(const LabeledTuple& other) const
diff --git a/tests/src/dbus_environment.cpp b/tests/src/dbus_environment.cpp
index a0f454e..dd00d94 100644
--- a/tests/src/dbus_environment.cpp
+++ b/tests/src/dbus_environment.cpp
@@ -77,9 +77,9 @@
                                      Milliseconds timeout)
 {
     auto& data = futures[std::string(name)];
-    auto ret = waitForFutures(
-        std::move(data), true, [](auto sum, auto val) { return sum && val; },
-        timeout);
+    auto ret = waitForFutures(std::move(data), true, [](auto sum, auto val) {
+        return sum && val;
+    }, timeout);
     data = std::vector<std::future<bool>>{};
     return ret;
 }
diff --git a/tests/src/dbus_environment.hpp b/tests/src/dbus_environment.hpp
index f3f7723..21191ae 100644
--- a/tests/src/dbus_environment.hpp
+++ b/tests/src/dbus_environment.hpp
@@ -82,9 +82,9 @@
         std::vector<std::future<T>> futures;
         futures.emplace_back(std::move(future));
 
-        return waitForFutures(
-            std::move(futures), T{},
-            [](auto, const auto& value) { return value; }, timeout);
+        return waitForFutures(std::move(futures), T{},
+                              [](auto, const auto& value) { return value; },
+                              timeout);
     }
 
     static bool waitForFuture(std::string_view name,
diff --git a/tests/src/stubs/dbus_sensor_object.cpp b/tests/src/stubs/dbus_sensor_object.cpp
index dbe95ca..224e1de 100644
--- a/tests/src/stubs/dbus_sensor_object.cpp
+++ b/tests/src/stubs/dbus_sensor_object.cpp
@@ -14,8 +14,7 @@
     boost::asio::io_context& ioc,
     const std::shared_ptr<sdbusplus::asio::connection>& bus,
     const std::shared_ptr<sdbusplus::asio::object_server>& objServer) :
-    ioc(ioc),
-    bus(bus), objServer(objServer)
+    ioc(ioc), bus(bus), objServer(objServer)
 {
     sensorIface = objServer->add_unique_interface(path(), interface(),
                                                   [this](auto& iface) {
diff --git a/tests/src/test_discrete_threshold.cpp b/tests/src/test_discrete_threshold.cpp
index 43a36c0..36d3a29 100644
--- a/tests/src/test_discrete_threshold.cpp
+++ b/tests/src/test_discrete_threshold.cpp
@@ -135,8 +135,7 @@
 
         UpdateParams(size_t sensor, double value,
                      Milliseconds sleepAfter = 0ms) :
-            sensor(sensor),
-            value(value), sleepAfter(sleepAfter)
+            sensor(sensor), value(value), sleepAfter(sleepAfter)
         {}
     };
 
@@ -148,8 +147,7 @@
 
         ExpectedParams(size_t sensor, double value,
                        Milliseconds waitMin = 0ms) :
-            sensor(sensor),
-            value(value), waitMin(waitMin)
+            sensor(sensor), value(value), waitMin(waitMin)
         {}
     };
 
diff --git a/tests/src/test_numeric_threshold.cpp b/tests/src/test_numeric_threshold.cpp
index a71f003..587a1bb 100644
--- a/tests/src/test_numeric_threshold.cpp
+++ b/tests/src/test_numeric_threshold.cpp
@@ -89,8 +89,7 @@
 
         UpdateParams(size_t sensor, double value,
                      Milliseconds sleepAfter = 0ms) :
-            sensor(sensor),
-            value(value), sleepAfter(sleepAfter)
+            sensor(sensor), value(value), sleepAfter(sleepAfter)
         {}
     };
 
@@ -102,8 +101,7 @@
 
         ExpectedParams(size_t sensor, double value,
                        Milliseconds waitMin = 0ms) :
-            sensor(sensor),
-            value(value), waitMin(waitMin)
+            sensor(sensor), value(value), waitMin(waitMin)
         {}
     };
 
diff --git a/tests/src/test_report.cpp b/tests/src/test_report.cpp
index e4e5510..709efdd 100644
--- a/tests/src/test_report.cpp
+++ b/tests/src/test_report.cpp
@@ -199,8 +199,7 @@
         DbusEnvironment::getBus()->async_method_call(
             [&methodPromise](boost::system::error_code ec) {
             methodPromise.set_value(ec);
-        },
-            DbusEnvironment::serviceName(), path, interface, method);
+        }, DbusEnvironment::serviceName(), path, interface, method);
         return DbusEnvironment::waitForFuture(methodPromise.get_future());
     }
 
@@ -642,8 +641,8 @@
         std::make_pair("ReportActions", nlohmann::json(utils::transform(
                                             defaultParams().reportActions(),
                                             [](const auto v) {
-    return utils::toUnderlying(v);
-}))),
+                                                return utils::toUnderlying(v);
+                                            }))),
         std::make_pair("Interval",
                        nlohmann::json(defaultParams().interval().count())),
         std::make_pair("AppendLimit",
diff --git a/tests/src/test_trigger.cpp b/tests/src/test_trigger.cpp
index 3e5818a..cfe0e15 100644
--- a/tests/src/test_trigger.cpp
+++ b/tests/src/test_trigger.cpp
@@ -141,8 +141,7 @@
         DbusEnvironment::getBus()->async_method_call(
             [&methodPromise](boost::system::error_code ec) {
             methodPromise.set_value(ec);
-        },
-            DbusEnvironment::serviceName(), path, Trigger::deleteIfaceName,
+        }, DbusEnvironment::serviceName(), path, Trigger::deleteIfaceName,
             "Delete");
         return DbusEnvironment::waitForFuture(methodPromise.get_future());
     }
