From 730e5dde39333cb2f63c72a7d7152bee5c4dbb05 Mon Sep 17 00:00:00 2001 From: Ben Longbons Date: Sat, 8 Feb 2014 15:09:25 -0800 Subject: Implement AString --- src/io/write_test.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'src/io/write_test.cpp') diff --git a/src/io/write_test.cpp b/src/io/write_test.cpp index a9736b8..f703850 100644 --- a/src/io/write_test.cpp +++ b/src/io/write_test.cpp @@ -5,7 +5,7 @@ #include #include -#include "../strings/fstring.hpp" +#include "../strings/astring.hpp" #include "../strings/mstring.hpp" #include "../strings/xstring.hpp" @@ -35,7 +35,7 @@ public: { rfd.close(); } - FString slurp() + AString slurp() { MString tmp; char buf[4096]; @@ -52,7 +52,7 @@ public: break; tmp += XString(buf + 0, buf + rv, nullptr); } - return FString(tmp); + return AString(tmp); } }; @@ -73,10 +73,10 @@ TEST(io, write2) PipeWriter pw(true); io::WriteFile& wf = pw.wf; wf.really_put("Hello, ", 7); - EXPECT_EQ("", std::string(pw.slurp().c_str())); + EXPECT_EQ("", pw.slurp()); wf.put_line("World!"); wf.really_put("XXX", 3); - EXPECT_EQ("Hello, World!\n", std::string(pw.slurp().c_str())); + EXPECT_EQ("Hello, World!\n", pw.slurp()); EXPECT_TRUE(wf.close()); - EXPECT_EQ("XXX", std::string(pw.slurp().c_str())); + EXPECT_EQ("XXX", pw.slurp()); } -- cgit v1.2.3-70-g09d2