X-Git-Url: https://feistymeow.org/gitweb/?a=blobdiff_plain;f=nucleus%2Flibrary%2Ftests_basis%2Ftest_string.cpp;h=04c7f0d2defa55c52883c59919264418c86ddcb4;hb=e7ace7a4aacb5178f5c33fd49f2479622d929679;hp=f89318a9df4862ff6d541b0ebb128cbdb2729795;hpb=457b128b77b5b4a0b7dd3094de543de2ce1477ad;p=feisty_meow.git diff --git a/nucleus/library/tests_basis/test_string.cpp b/nucleus/library/tests_basis/test_string.cpp index f89318a9..04c7f0d2 100644 --- a/nucleus/library/tests_basis/test_string.cpp +++ b/nucleus/library/tests_basis/test_string.cpp @@ -33,7 +33,7 @@ #include #include -#ifdef __WIN32__ +#ifdef _MSC_VER #include #endif #include @@ -184,8 +184,8 @@ void test_string::run_test_02() *fred3 += *fred2; // testing adding a null to a string. - *fred2 += (char *)NIL; - *fred3 += (char *)NIL; + *fred2 += (char *)NULL_POINTER; + *fred3 += (char *)NULL_POINTER; #ifdef DEBUG_STRING_TEST LOG(astring("[ ") + *fred1 + " & " + *fred2 + "] -> " + *fred3); @@ -512,7 +512,7 @@ void test_string::run_test_12() void test_string::run_test_13() { -// FUNCDEF("run_test_13"); + FUNCDEF("run_test_13"); // check for possible memory leaks in these combined ops.... 13th. const astring churg("borjh sjh oiweoklj"); astring pud = churg; @@ -603,7 +603,7 @@ void test_string::run_test_16() void test_string::run_test_17() { -// FUNCDEF("run_test_17"); + FUNCDEF("run_test_17"); // 17th test checks construction of temporaries. /* this test set causes the obnoxious 16 bit codeguard error from hell, as does use of temporary objects in ostream << operators. argh! */ @@ -775,6 +775,7 @@ void test_string::run_test_23() void test_string::run_test_24() { FUNCDEF("run_test_24"); +#ifndef __GNU_WINDOWS__ #ifdef __WIN32__ // 24th test group tests _bstr_t conversions. _bstr_t beast("abcdefgh"); @@ -793,6 +794,7 @@ void test_string::run_test_24() _bstr_t pork = string_convert::to_bstr_t(jethro); ASSERT_FALSE(strcmp(pork.operator char *(), jethro.s()), "second test failed comparison"); #endif +#endif } void test_string::run_test_25() @@ -810,7 +812,7 @@ void test_string::run_test_25() void test_string::run_test_26() { -// FUNCDEF("run_test_26"); + FUNCDEF("run_test_26"); // 26th test group does simple time_stamp::notarize operations. these are more for // ensuring boundschecker gets to see some of this. astring t2 = time_stamp::notarize(false); @@ -819,7 +821,7 @@ void test_string::run_test_26() void test_string::run_test_27() { -// FUNCDEF("run_test_27"); + FUNCDEF("run_test_27"); // 27th test group plays around with idate in an attempt to get // boundschecker to complain. timely::day_in_year d1 = date_now(); @@ -859,7 +861,7 @@ void test_string::run_test_29() void standard_sprintf_test(const char *parm_string) { -// FUNCDEF("standard_sprintf_test"); + FUNCDEF("standard_sprintf_test"); astring print_into(' ', 20000); print_into[0] = '\0'; //check these!!!: @@ -993,7 +995,7 @@ void test_string::run_test_33() void test_string::run_test_34() { -// FUNCDEF("run_test_34"); + FUNCDEF("run_test_34"); //not in use right now. @@ -1070,7 +1072,7 @@ void test_string::run_test_37() void test_string::run_test_38() { -// FUNCDEF("run_test_38"); + FUNCDEF("run_test_38"); double to_print = 2.345; a_sprintf non_deadly("%.1f", to_print); /// LOG(astring("printed: ") + non_deadly);