mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 18:57:35 +00:00
Everywhere: Use LibFileSystem
where trivial
This commit is contained in:
parent
edab0cbf41
commit
1d24f394c6
115 changed files with 275 additions and 228 deletions
|
@ -27,6 +27,6 @@ serenity_component(
|
|||
TARGETS test-test262
|
||||
)
|
||||
add_executable(test-test262 test-test262.cpp)
|
||||
target_link_libraries(test-test262 PRIVATE LibMain LibCore)
|
||||
target_link_libraries(test-test262 PRIVATE LibMain LibCore LibFileSystem)
|
||||
serenity_set_implicit_links(test-test262)
|
||||
install(TARGETS test-test262 RUNTIME DESTINATION bin OPTIONAL)
|
||||
|
|
|
@ -13,10 +13,10 @@
|
|||
#include <AK/QuickSort.h>
|
||||
#include <AK/Vector.h>
|
||||
#include <LibCore/ArgsParser.h>
|
||||
#include <LibCore/DeprecatedFile.h>
|
||||
#include <LibCore/File.h>
|
||||
#include <LibCore/Process.h>
|
||||
#include <LibCore/System.h>
|
||||
#include <LibFileSystem/FileSystem.h>
|
||||
#include <LibMain/Main.h>
|
||||
#include <LibTest/TestRunnerUtil.h>
|
||||
#include <spawn.h>
|
||||
|
@ -322,7 +322,7 @@ ErrorOr<int> serenity_main(Main::Arguments arguments)
|
|||
// Normalize the path to ensure filenames are consistent
|
||||
Vector<DeprecatedString> paths;
|
||||
|
||||
if (!Core::DeprecatedFile::is_directory(test_directory)) {
|
||||
if (!FileSystem::is_directory(test_directory)) {
|
||||
paths.append(test_directory);
|
||||
} else {
|
||||
Test::iterate_directory_recursively(LexicalPath::canonicalized_path(test_directory), [&](DeprecatedString const& file_path) {
|
||||
|
|
|
@ -6,10 +6,10 @@
|
|||
|
||||
#include <AK/Base64.h>
|
||||
#include <LibCore/ConfigFile.h>
|
||||
#include <LibCore/DeprecatedFile.h>
|
||||
#include <LibCore/EventLoop.h>
|
||||
#include <LibCrypto/ASN1/ASN1.h>
|
||||
#include <LibCrypto/ASN1/PEM.h>
|
||||
#include <LibFileSystem/FileSystem.h>
|
||||
#include <LibTLS/TLSv12.h>
|
||||
#include <LibTest/TestCase.h>
|
||||
|
||||
|
@ -28,11 +28,11 @@ DeprecatedString locate_ca_certs_file();
|
|||
|
||||
DeprecatedString locate_ca_certs_file()
|
||||
{
|
||||
if (Core::DeprecatedFile::exists(ca_certs_file)) {
|
||||
if (FileSystem::exists(ca_certs_file)) {
|
||||
return ca_certs_file;
|
||||
}
|
||||
auto on_target_path = DeprecatedString("/etc/cacert.pem");
|
||||
if (Core::DeprecatedFile::exists(on_target_path)) {
|
||||
if (FileSystem::exists(on_target_path)) {
|
||||
return on_target_path;
|
||||
}
|
||||
return "";
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue