Differences From Artifact [bb51e4a860]:
- File
tests/OFStringTests.m
— part of check-in
[156b850131]
at
2018-03-11 12:55:20
on branch trunk
— Remove OF_PATH_* macros
These were way too simplistic, as paths differ in more than just that on
various operating systems. (user: js, size: 37241) [annotate] [blame] [check-ins using]
To Artifact [067d094bf5]:
- File tests/OFStringTests.m — part of check-in [c6299422a1] at 2018-03-11 21:43:54 on branch trunk — Add -[OFString isAbsolutePath] (user: js, size: 37638) [annotate] [blame] [check-ins using]
︙ | ︙ | |||
548 549 550 551 552 553 554 555 556 557 558 559 560 561 | TEST(@"-[stringByAppendingString:]", [[C(@"foo") stringByAppendingString: @"bar"] isEqual: @"foobar"]) TEST(@"-[stringByPrependingString:]", [[C(@"foo") stringByPrependingString: @"bar"] isEqual: @"barfoo"]) #ifdef OF_HAVE_FILES s[0] = [mutableStringClass stringWithString: @"foo"]; # if defined(OF_WINDOWS) || defined(OF_MSDOS) [s[0] appendString: @"\\"]; # else [s[0] appendString: @"/"]; # endif [s[0] appendString: @"bar"]; | > > > > > > > > > > | 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 | TEST(@"-[stringByAppendingString:]", [[C(@"foo") stringByAppendingString: @"bar"] isEqual: @"foobar"]) TEST(@"-[stringByPrependingString:]", [[C(@"foo") stringByPrependingString: @"bar"] isEqual: @"barfoo"]) #ifdef OF_HAVE_FILES # if defined(OF_WINDOWS) || defined(OF_MSDOS) TEST(@"-[isAbsolutePath]", [C(@"C:\\foo") isAbsolutePath] && [C(@"a:/foo") isAbsolutePath] && ![C(@"foo") isAbsolutePath] && ![C(@"b:foo") isAbsolutePath]) # else TEST(@"-[isAbsolutePath]", [C(@"/foo") isAbsolutePath] && [C(@"/foo/bar") isAbsolutePath] && ![C(@"foo/bar") isAbsolutePath] && ![C(@"foo") isAbsolutePath]) # endif s[0] = [mutableStringClass stringWithString: @"foo"]; # if defined(OF_WINDOWS) || defined(OF_MSDOS) [s[0] appendString: @"\\"]; # else [s[0] appendString: @"/"]; # endif [s[0] appendString: @"bar"]; |
︙ | ︙ |