aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/linden/indra/test/llsdserialize_tut.cpp
diff options
context:
space:
mode:
authorJacek Antonelli2008-09-06 18:24:57 -0500
committerJacek Antonelli2008-09-06 18:25:07 -0500
commit798d367d54a6c6379ad355bd8345fa40e31e7fe9 (patch)
tree1921f1708cd0240648c97bc02df2c2ab5f2fc41e /linden/indra/test/llsdserialize_tut.cpp
parentSecond Life viewer sources 1.20.15 (diff)
downloadmeta-impy-798d367d54a6c6379ad355bd8345fa40e31e7fe9.zip
meta-impy-798d367d54a6c6379ad355bd8345fa40e31e7fe9.tar.gz
meta-impy-798d367d54a6c6379ad355bd8345fa40e31e7fe9.tar.bz2
meta-impy-798d367d54a6c6379ad355bd8345fa40e31e7fe9.tar.xz
Second Life viewer sources 1.21.0-RC
Diffstat (limited to 'linden/indra/test/llsdserialize_tut.cpp')
-rw-r--r--linden/indra/test/llsdserialize_tut.cpp16
1 files changed, 15 insertions, 1 deletions
diff --git a/linden/indra/test/llsdserialize_tut.cpp b/linden/indra/test/llsdserialize_tut.cpp
index fe732cd..4b4c787 100644
--- a/linden/indra/test/llsdserialize_tut.cpp
+++ b/linden/indra/test/llsdserialize_tut.cpp
@@ -44,7 +44,19 @@
44 44
45// These tests take too long to run on Windows. JC 45// These tests take too long to run on Windows. JC
46// Yeah, who cares if windows works or not, right? Phoenix 46// Yeah, who cares if windows works or not, right? Phoenix
47#if !LL_WINDOWS 47// Change the 'FALSE' here to 'TRUE' to enable them on Windows
48#define RUN_PARSER_TESTS_ON_WINDOWS FALSE
49
50#define RUN_PARSER_TESTS (!LL_WINDOWS || RUN_PARSER_TESTS_ON_WINDOWS)
51
52
53
54#if RUN_PARSER_TESTS
55
56#if LL_WINDOWS
57#include <winsock2.h>
58typedef U32 uint32_t;
59#endif
48 60
49namespace tut 61namespace tut
50{ 62{
@@ -225,6 +237,7 @@ namespace tut
225 mFormatter->format(v, stream); 237 mFormatter->format(v, stream);
226 //llinfos << "checkRoundTrip: length " << stream.str().length() << llendl; 238 //llinfos << "checkRoundTrip: length " << stream.str().length() << llendl;
227 LLSD w; 239 LLSD w;
240 mParser->reset(); // reset() call is needed since test code re-uses mParser
228 mParser->parse(stream, w, stream.str().size()); 241 mParser->parse(stream, w, stream.str().size());
229 242
230 try 243 try
@@ -475,6 +488,7 @@ namespace tut
475 input.str(in); 488 input.str(in);
476 489
477 LLSD parsed_result; 490 LLSD parsed_result;
491 mParser->reset(); // reset() call is needed since test code re-uses mParser
478 S32 parsed_count = mParser->parse(input, parsed_result, in.size()); 492 S32 parsed_count = mParser->parse(input, parsed_result, in.size());
479 ensure_equals(msg, parsed_result, expected_value); 493 ensure_equals(msg, parsed_result, expected_value);
480 494