* fixed Adopt(BString, len) test, as after adopt the source string should

be empty, thus the pointer into that string should point to empty data...



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24104 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Karsten Heimrich 2008-02-24 22:33:46 +00:00
parent 93608e10d1
commit 4f841cf2fa
1 changed files with 1 additions and 1 deletions

View File

@ -95,7 +95,7 @@ StringAssignTest::PerformTest(void)
const char *oldString = newstring.String();
str = new BString;
str->Adopt(newstring, 2);
CPPUNIT_ASSERT(strncmp(str->String(), oldString, 2) == 0);
CPPUNIT_ASSERT(strncmp(str->String(), "SomethingElseAgain", 2) == 0);
CPPUNIT_ASSERT(str->Length() == 2);
CPPUNIT_ASSERT(strcmp(newstring.String(), "") == 0);
delete str;