Remove non-functional tests
These tests were built against boost-dbus, and havne't been ported
forward. While ideally someone could, right now they are causing clang
builds to fail; We can revisit in the future if someone wants to spend
the effort to revive these tests.
Change-Id: I90ee49f4c6afcf44b3ce119fa44c59ad13907d8e
Signed-off-by: Ed Tanous <edtanous@google.com>
diff --git a/tests/meson.build b/tests/meson.build
index 008ba19..28915d6 100644
--- a/tests/meson.build
+++ b/tests/meson.build
@@ -25,31 +25,6 @@
ut_deps_list += default_deps
-have_boost_dbus = meson.get_compiler('cpp').has_header('dbus/connection.hpp')
-if have_boost_dbus
-test(
- 'test_hwmon_temp_sensor',
- executable(
- 'test_hwmon_temp_sensor',
- 'test_HwmonTempSensor.cpp',
- dependencies: ut_deps_list,
- implicit_include_directories: false,
- include_directories: '../src',
- )
-)
-
-test(
- 'test_tach_sensor',
- executable(
- 'test_tach_sensor',
- 'test_TachSensor.cpp',
- dependencies: ut_deps_list,
- implicit_include_directories: false,
- include_directories: '../src',
- )
-)
-endif
-
test(
'test_utils',
executable(
diff --git a/tests/test_HwmonTempSensor.cpp b/tests/test_HwmonTempSensor.cpp
deleted file mode 100644
index 6ae65ce..0000000
--- a/tests/test_HwmonTempSensor.cpp
+++ /dev/null
@@ -1,52 +0,0 @@
-#include "HwmonTempSensor.hpp"
-#include "dbus/connection.hpp"
-
-#include <nlohmann/json.hpp>
-
-#include <fstream>
-
-#include <gtest/gtest.h>
-
-TEST(HwmonTempSensor, TestTMP75)
-{
- boost::asio::io_service io;
- auto system_bus = std::make_shared<dbus::connection>(io, dbus_t::session);
- dbus::DbusObjectServer object_server(system_bus);
-
- std::vector<thresholds::Threshold> sensor_thresholds;
- auto t = thresholds::Threshold(thresholds::Level::CRITICAL,
- thresholds::Direction::LOW, 80);
- sensor_thresholds.emplace_back(t);
-
- std::ofstream test_file("test0.txt");
- test_file << "28\n";
- test_file.close();
- auto filename = std::string("test0.txt");
- auto tempsensname = std::string("test sensor");
- HwmonTempSensor test(filename, object_server, io, tempsensname,
- std::move(sensor_thresholds));
-
- std::remove("test0.txt");
-}
-
-TEST(HwmonTempSensor, TestTMP421)
-{
- boost::asio::io_service io;
- auto system_bus = std::make_shared<dbus::connection>(io, dbus_t::session);
- dbus::DbusObjectServer object_server(system_bus);
-
- std::vector<thresholds::Threshold> sensor_thresholds;
- auto t = thresholds::Threshold(thresholds::Level::WARNING,
- thresholds::Direction::HIGH, 80);
- sensor_thresholds.emplace_back(t);
-
- std::ofstream test_file("test1.txt");
- test_file << "28\n";
- test_file.close();
- auto filename = std::string("test1.txt");
- auto tempsensname = std::string("test sensor");
- HwmonTempSensor test(filename, object_server, io, tempsensname,
- std::move(sensor_thresholds));
-
- std::remove("test1.txt");
-}
diff --git a/tests/test_TachSensor.cpp b/tests/test_TachSensor.cpp
deleted file mode 100644
index 01397d3..0000000
--- a/tests/test_TachSensor.cpp
+++ /dev/null
@@ -1,30 +0,0 @@
-#include "TachSensor.hpp"
-#include "Thresholds.hpp"
-
-#include <dbus/connection.hpp>
-#include <nlohmann/json.hpp>
-
-#include <fstream>
-
-#include <gtest/gtest.h>
-
-TEST(TachSensor, TestTachSensor)
-{
- boost::asio::io_service io;
- auto system_bus = std::make_shared<dbus::connection>(io, dbus_t::session);
- dbus::DbusObjectServer object_server(system_bus);
-
- std::vector<thresholds::Threshold> sensor_thresholds;
- auto t = thresholds::Threshold(thresholds::Level::CRITICAL,
- thresholds::Direction::LOW, 1000);
- sensor_thresholds.emplace_back(t);
-
- std::ofstream test_file("test.txt");
- test_file << "10000\n";
- test_file.close();
- auto filename = std::string("test.txt");
- auto fanname = std::string("test fan");
- TachSensor test(filename, object_server, system_bus, io, fanname,
- std::move(sensor_thresholds));
- std::remove("test.txt");
-}