-
Notifications
You must be signed in to change notification settings - Fork 37.7k
test: Split overly large util_tests.cpp file #26489
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
The head ref may contain hidden characters: "2211-test-split-\u{1F310}"
Conversation
The following sections might be updated with supplementary metadata relevant to reviewers and maintainers. ConflictsReviewers, this pull request conflicts with the following ones:
If you consider this pull request important, please also help to review the conflicting pull requests. Ideally, start with the one that should be merged first. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Concept ACK
I successfully compiled the branch and ran the test on it.
I think some dependencies would be redundant and can be removed.
in src/test/util_tests.cpp
#include <test/util/logging.h>
#include <test/util/str.h>
and, in src/test/argsman_tests.cpp
fae2420
to
fa4ec1b
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ACK fa4ec1b
- The redundant dependencies are removed from the src/test/util_tests.cpp file.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ACK fa4ec1b
// Distributed under the MIT software license, see the accompanying | ||
// file COPYING or http://www.opensource.org/licenses/mit-license.php. | ||
|
||
#include <util/system.h> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit
diff --git a/src/test/argsman_tests.cpp b/src/test/argsman_tests.cpp
index d00876bc7..76d64e0d5 100644
--- a/src/test/argsman_tests.cpp
+++ b/src/test/argsman_tests.cpp
@@ -2,13 +2,13 @@
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
-#include <util/system.h>
#include <fs.h>
#include <sync.h>
#include <test/util/logging.h>
#include <test/util/setup_common.h>
#include <test/util/str.h>
#include <util/strencodings.h>
+#include <util/system.h>
#include <univalue.h>
#include <array>
ACK fa4ec1b for: macOS x84_64: macOS Arm64: |
The file has ~3kLOC and is slow to compile.
Fix both issues by splitting it. (On my machine the compilation goes from 25 seconds previously to 17+10 seconds for the two smaller files)
To review,
--color-moved=dimmed-zebra
can be used.