summaryrefslogtreecommitdiffstatshomepage
path: root/3rdparty/rapidjson/test/unittest/ostreamwrappertest.cpp
diff options
context:
space:
mode:
Diffstat (limited to '3rdparty/rapidjson/test/unittest/ostreamwrappertest.cpp')
-rw-r--r--3rdparty/rapidjson/test/unittest/ostreamwrappertest.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/3rdparty/rapidjson/test/unittest/ostreamwrappertest.cpp b/3rdparty/rapidjson/test/unittest/ostreamwrappertest.cpp
index b1d1cd827fc..be9e429cadc 100644
--- a/3rdparty/rapidjson/test/unittest/ostreamwrappertest.cpp
+++ b/3rdparty/rapidjson/test/unittest/ostreamwrappertest.cpp
@@ -1,6 +1,6 @@
// Tencent is pleased to support the open source community by making RapidJSON available.
//
-// Copyright (C) 2015 THL A29 Limited, a Tencent company, and Milo Yip. All rights reserved.
+// Copyright (C) 2015 THL A29 Limited, a Tencent company, and Milo Yip.
//
// Licensed under the MIT License (the "License"); you may not use this file except
// in compliance with the License. You may obtain a copy of the License at
@@ -69,14 +69,15 @@ static void TestFileStream() {
const char* s = "Hello World!\n";
{
- ofstream ofs(filename, ios::out | ios::binary);
- BasicOStreamWrapper<ofstream> osw(ofs);
+ FileStreamType ofs(filename, ios::out | ios::binary);
+ BasicOStreamWrapper<FileStreamType> osw(ofs);
for (const char* p = s; *p; p++)
osw.Put(*p);
osw.Flush();
}
fp = fopen(filename, "r");
+ ASSERT_TRUE( fp != NULL );
for (const char* p = s; *p; p++)
EXPECT_EQ(*p, static_cast<char>(fgetc(fp)));
fclose(fp);