Close output stream in IO tests before re-opening
This commit is contained in:
parent
9191117120
commit
08a1c5c2eb
|
@ -568,6 +568,7 @@ void IoTests::testCopyWithNativeFileStream()
|
|||
const auto isAborted = [] { return false; };
|
||||
const auto callback = [&percentage](double p) { percentage = p; };
|
||||
testFile.seekg(0);
|
||||
outputStream.close();
|
||||
outputStream.open(outputPath, ios_base::out | ios_base::trunc | ios_base::binary);
|
||||
copyHelper.callbackCopy(testFile, outputStream, 50, isAborted, callback);
|
||||
CPPUNIT_ASSERT_EQUAL(1.0, percentage);
|
||||
|
|
Loading…
Reference in New Issue