aboutsummaryrefslogtreecommitdiff
path: root/src/zencore/basicfile.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/zencore/basicfile.cpp')
-rw-r--r--src/zencore/basicfile.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/zencore/basicfile.cpp b/src/zencore/basicfile.cpp
index a181bbd66..ea526399c 100644
--- a/src/zencore/basicfile.cpp
+++ b/src/zencore/basicfile.cpp
@@ -590,7 +590,7 @@ TemporaryFile::MoveTemporaryIntoPlace(std::filesystem::path FinalFileName, std::
// deleting the temporary file
BasicFile::Close();
- std::filesystem::rename(m_TempPath, FinalFileName, Ec);
+ RenameFile(m_TempPath, FinalFileName, Ec);
if (Ec)
{
@@ -984,9 +984,9 @@ TEST_CASE("TemporaryFile")
TmpFile.CreateTemporary(std::filesystem::current_path(), Ec);
CHECK(!Ec);
Path = TmpFile.GetPath();
- CHECK(std::filesystem::exists(Path));
+ CHECK(IsFile(Path));
}
- CHECK(std::filesystem::exists(Path) == false);
+ CHECK(IsFile(Path) == false);
}
SUBCASE("MoveIntoPlace")
@@ -997,11 +997,11 @@ TEST_CASE("TemporaryFile")
CHECK(!Ec);
std::filesystem::path TempPath = TmpFile.GetPath();
std::filesystem::path FinalPath = std::filesystem::current_path() / "final";
- CHECK(std::filesystem::exists(TempPath));
+ CHECK(IsFile(TempPath));
TmpFile.MoveTemporaryIntoPlace(FinalPath, Ec);
CHECK(!Ec);
- CHECK(std::filesystem::exists(TempPath) == false);
- CHECK(std::filesystem::exists(FinalPath));
+ CHECK(IsFile(TempPath) == false);
+ CHECK(IsFile(FinalPath));
}
}