mirror of
https://github.com/MaskRay/ccls.git
synced 2025-03-20 07:46:09 +00:00
Write test using binary, otherwise \n will become \r\n leading to double \r\r\n.
This commit is contained in:
parent
d9b9e5e227
commit
2a17f66792
@ -450,7 +450,8 @@ void UpdateTestExpectation(const std::string& filename,
|
||||
str.replace(it, expectation.size(), actual);
|
||||
|
||||
// Write it back out.
|
||||
std::ofstream of(filename, std::ios::out | std::ios::trunc);
|
||||
std::ofstream of(filename,
|
||||
std::ios::out | std::ios::trunc | std::ios::binary);
|
||||
of.write(str.c_str(), str.size());
|
||||
of.close();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user