From e6fc69187632612974cc650c28fe17d5a6d38e6a Mon Sep 17 00:00:00 2001 From: Mike Buland Date: Sat, 13 May 2006 02:16:06 +0000 Subject: Fixed a bug in the tester. --- src/test/serializetext.cpp | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) (limited to 'src/test') diff --git a/src/test/serializetext.cpp b/src/test/serializetext.cpp index e7e92d2..f6be7d3 100644 --- a/src/test/serializetext.cpp +++ b/src/test/serializetext.cpp @@ -1,24 +1,27 @@ #include "serializertext.h" +#include "staticstring.h" +#include int main() { + StaticString s("You're a dog!!"); SerializerText ar("hello.dat", false); - ar << 4; - ar << 3.993; - ar << true; + ar << 4 << 3.993 << true << s; ar.close(); - int one=0;float two=0.0;bool three=false; + int one=0;float two=0.0;bool three=false; s = ""; SerializerText ar2("hello.dat", true); ar2 >> one; ar2 >> two; ar2 >> three; + ar2 >> s; - printf("out: %d, %d, %s\n", one, two, three); + //printf("out: %d, %f, %s, \"%s\"\n", one, two, (three ? "true" : "false"), s.getString()); + std::cout << one << ", " << two << ", " << three << ", " << s.getString() << "\n"; return 0; } -- cgit v1.2.3