summaryrefslogtreecommitdiff
path: root/Source/UnitTests
diff options
context:
space:
mode:
authorMartino Fontana <tinozzo123@gmail.com>2026-01-23 21:30:01 +0100
committerMartino Fontana <tinozzo123@gmail.com>2026-01-25 16:12:15 +0100
commita14c88ba67a51b0a563a5fc800cd089e82ffacaf (patch)
tree4263ea748b1b70960a1e28ae89cd26a361be4faf /Source/UnitTests
parentcdbea8867df3d0a6fc375e78726dae95612fb1fd (diff)
Remove unused imports
Yellow squiggly lines begone! Done automatically on .cpp files through `run-clang-tidy`, with manual corrections to the mistakes. If an import is directly used, but is technically unnecessary since it's recursively imported by something else, it is *not* removed. The tool doesn't touch .h files, so I did some of them by hand while fixing errors due to old recursive imports. Not everything is removed, but the cleanup should be substantial enough. Because this done on Linux, code that isn't used on it is mostly untouched. (Hopefully no open PR is depending on these imports...)
Diffstat (limited to 'Source/UnitTests')
-rw-r--r--Source/UnitTests/Common/BusyLoopTest.cpp1
-rw-r--r--Source/UnitTests/Common/x64EmitterTest.cpp1
-rw-r--r--Source/UnitTests/Core/PageFaultTest.cpp2
-rw-r--r--Source/UnitTests/Core/PatchAllowlistTest.cpp3
-rw-r--r--Source/UnitTests/Core/PowerPC/Jit64Common/ConvertDoubleToSingle.cpp7
-rw-r--r--Source/UnitTests/Core/PowerPC/Jit64Common/Fres.cpp1
-rw-r--r--Source/UnitTests/Core/PowerPC/Jit64Common/Frsqrte.cpp2
-rw-r--r--Source/UnitTests/UnitTestsMain.cpp4
-rw-r--r--Source/UnitTests/VideoCommon/VertexLoaderTest.cpp2
9 files changed, 1 insertions, 22 deletions
diff --git a/Source/UnitTests/Common/BusyLoopTest.cpp b/Source/UnitTests/Common/BusyLoopTest.cpp
index 8cb62ca1af..27d04b407c 100644
--- a/Source/UnitTests/Common/BusyLoopTest.cpp
+++ b/Source/UnitTests/Common/BusyLoopTest.cpp
@@ -1,7 +1,6 @@
// Copyright 2014 Dolphin Emulator Project
// SPDX-License-Identifier: GPL-2.0-or-later
-#include <atomic>
#include <thread>
#include <gtest/gtest.h>
diff --git a/Source/UnitTests/Common/x64EmitterTest.cpp b/Source/UnitTests/Common/x64EmitterTest.cpp
index f38bb7c1b9..ef060e0a93 100644
--- a/Source/UnitTests/Common/x64EmitterTest.cpp
+++ b/Source/UnitTests/Common/x64EmitterTest.cpp
@@ -4,7 +4,6 @@
#include <cstring>
#include <disasm.h> // From Bochs, fallback included in Externals.
#include <gtest/gtest.h>
-#include <map>
#include <memory>
#include <vector>
diff --git a/Source/UnitTests/Core/PageFaultTest.cpp b/Source/UnitTests/Core/PageFaultTest.cpp
index c9c69d7d51..f780542761 100644
--- a/Source/UnitTests/Core/PageFaultTest.cpp
+++ b/Source/UnitTests/Core/PageFaultTest.cpp
@@ -2,11 +2,9 @@
// SPDX-License-Identifier: GPL-2.0-or-later
#include <chrono>
-#include <fmt/format.h>
#include "Common/CommonTypes.h"
#include "Common/ScopeGuard.h"
-#include "Common/Timer.h"
#include "Core/Core.h"
#include "Core/MemTools.h"
#include "Core/PowerPC/JitCommon/JitBase.h"
diff --git a/Source/UnitTests/Core/PatchAllowlistTest.cpp b/Source/UnitTests/Core/PatchAllowlistTest.cpp
index 85111fb607..4fa6f0f328 100644
--- a/Source/UnitTests/Core/PatchAllowlistTest.cpp
+++ b/Source/UnitTests/Core/PatchAllowlistTest.cpp
@@ -3,7 +3,6 @@
#ifdef USE_RETRO_ACHIEVEMENTS
-#include <array>
#include <map>
#include <string>
#include <string_view>
@@ -17,12 +16,10 @@
#include "Common/CommonPaths.h"
#include "Common/Crypto/SHA1.h"
#include "Common/FileUtil.h"
-#include "Common/IOFile.h"
#include "Common/IniFile.h"
#include "Common/JsonUtil.h"
#include "Core/AchievementManager.h"
#include "Core/ActionReplay.h"
-#include "Core/CheatCodes.h"
#include "Core/GeckoCode.h"
#include "Core/GeckoCodeConfig.h"
#include "Core/PatchEngine.h"
diff --git a/Source/UnitTests/Core/PowerPC/Jit64Common/ConvertDoubleToSingle.cpp b/Source/UnitTests/Core/PowerPC/Jit64Common/ConvertDoubleToSingle.cpp
index c9f69d0de1..36604ee735 100644
--- a/Source/UnitTests/Core/PowerPC/Jit64Common/ConvertDoubleToSingle.cpp
+++ b/Source/UnitTests/Core/PowerPC/Jit64Common/ConvertDoubleToSingle.cpp
@@ -1,23 +1,18 @@
// Copyright 2019 Dolphin Emulator Project
// SPDX-License-Identifier: GPL-2.0-or-later
-#include <cstring>
-#include <tuple>
-
#include "Common/CommonTypes.h"
#include "Common/ScopeGuard.h"
#include "Common/x64ABI.h"
#include "Core/Core.h"
-#include "Core/PowerPC/Gekko.h"
#include "Core/PowerPC/Interpreter/Interpreter_FPUtils.h"
#include "Core/PowerPC/Jit64/Jit.h"
#include "Core/PowerPC/Jit64Common/Jit64AsmCommon.h"
-#include "Core/PowerPC/Jit64Common/Jit64PowerPCState.h"
+#include "Core/PowerPC/Jit64Common/Jit64Constants.h"
#include "Core/System.h"
#include "../TestValues.h"
-#include <fmt/format.h>
#include <gtest/gtest.h>
namespace
diff --git a/Source/UnitTests/Core/PowerPC/Jit64Common/Fres.cpp b/Source/UnitTests/Core/PowerPC/Jit64Common/Fres.cpp
index d3377070ca..bf92c65999 100644
--- a/Source/UnitTests/Core/PowerPC/Jit64Common/Fres.cpp
+++ b/Source/UnitTests/Core/PowerPC/Jit64Common/Fres.cpp
@@ -15,7 +15,6 @@
#include "../TestValues.h"
-#include <fmt/format.h>
#include <gtest/gtest.h>
namespace
diff --git a/Source/UnitTests/Core/PowerPC/Jit64Common/Frsqrte.cpp b/Source/UnitTests/Core/PowerPC/Jit64Common/Frsqrte.cpp
index b395b4cd07..5af80075f0 100644
--- a/Source/UnitTests/Core/PowerPC/Jit64Common/Frsqrte.cpp
+++ b/Source/UnitTests/Core/PowerPC/Jit64Common/Frsqrte.cpp
@@ -2,7 +2,6 @@
// SPDX-License-Identifier: GPL-2.0-or-later
#include <bit>
-#include <cstring>
#include "Common/CommonTypes.h"
#include "Common/FloatUtils.h"
@@ -17,7 +16,6 @@
#include "../TestValues.h"
-#include <fmt/format.h>
#include <gtest/gtest.h>
namespace
diff --git a/Source/UnitTests/UnitTestsMain.cpp b/Source/UnitTests/UnitTestsMain.cpp
index 3edb1c1909..12b998125c 100644
--- a/Source/UnitTests/UnitTestsMain.cpp
+++ b/Source/UnitTests/UnitTestsMain.cpp
@@ -2,11 +2,7 @@
// SPDX-License-Identifier: GPL-2.0-or-later
// Based on gtest_main.cc
-#include <cstdio>
-#include <fmt/format.h>
-
#include "Common/MsgHandler.h"
-#include "Core/Core.h"
#include "gtest/gtest.h"
diff --git a/Source/UnitTests/VideoCommon/VertexLoaderTest.cpp b/Source/UnitTests/VideoCommon/VertexLoaderTest.cpp
index 936f2e35c1..1b1d8f38ba 100644
--- a/Source/UnitTests/VideoCommon/VertexLoaderTest.cpp
+++ b/Source/UnitTests/VideoCommon/VertexLoaderTest.cpp
@@ -5,12 +5,10 @@
#include <limits>
#include <memory>
#include <tuple>
-#include <type_traits>
#include <unordered_set>
#include <gtest/gtest.h> // NOLINT
-#include "Common/Common.h"
#include "Common/MathUtil.h"
#include "VideoCommon/CPMemory.h"
#include "VideoCommon/DataReader.h"