Differences From Artifact [3c7c95496c]:
- File
tests/OFStringTests.m
— part of check-in
[c5e7dd679b]
at
2013-09-17 16:12:37
on branch trunk
— Work around Android bugs.
Includes:
* Check environ against NULL before using it, since Android sets it to
NULL.
* Cast st_size of struct stat to off_t. Android uses long long for
st_size as its off_t is only 32 bit, but st_size should be off_t
according to POSIX.
* Android's strtod() does not accept 0x, as specified by C99. Thus,
the test is disabled if __ANDROID__ is defined. (user: js, size: 24162) [annotate] [blame] [check-ins using]
To Artifact [fe0644a99a]:
- File tests/OFStringTests.m — part of check-in [7561b9244e] at 2013-10-30 00:09:39 on branch trunk — OFStringTests: Fix a path test on Win32. (user: js, size: 24278) [annotate] [blame] [check-ins using]
︙ | ︙ | |||
345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 | [[@"foo" stringByDeletingLastPathComponent] isEqual: @"."]) TEST(@"-[stringByDeletingPathExtension]", [[@"foo.bar" stringByDeletingPathExtension] isEqual: @"foo"] && [[@"foo..bar" stringByDeletingPathExtension] isEqual: @"foo."] && [[@"/foo./bar" stringByDeletingPathExtension] isEqual: @"/foo./bar"] && [[@"/foo./bar.baz" stringByDeletingPathExtension] isEqual: @"/foo./bar"] && [[@"foo.bar/" stringByDeletingPathExtension] isEqual: @"foo"] && [[@".foo" stringByDeletingPathExtension] isEqual: @".foo"] && [[@".foo.bar" stringByDeletingPathExtension] isEqual: @".foo"]) TEST(@"-[decimalValue]", [@"1234" decimalValue] == 1234 && [@"\r\n+123 " decimalValue] == 123 && | > > > > > | 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 | [[@"foo" stringByDeletingLastPathComponent] isEqual: @"."]) TEST(@"-[stringByDeletingPathExtension]", [[@"foo.bar" stringByDeletingPathExtension] isEqual: @"foo"] && [[@"foo..bar" stringByDeletingPathExtension] isEqual: @"foo."] && [[@"/foo./bar" stringByDeletingPathExtension] isEqual: @"/foo./bar"] && #ifndef _WIN32 [[@"/foo./bar.baz" stringByDeletingPathExtension] isEqual: @"/foo./bar"] && #else [[@"/foo./bar.baz" stringByDeletingPathExtension] isEqual: @"\\foo.\\bar"] && #endif [[@"foo.bar/" stringByDeletingPathExtension] isEqual: @"foo"] && [[@".foo" stringByDeletingPathExtension] isEqual: @".foo"] && [[@".foo.bar" stringByDeletingPathExtension] isEqual: @".foo"]) TEST(@"-[decimalValue]", [@"1234" decimalValue] == 1234 && [@"\r\n+123 " decimalValue] == 123 && |
︙ | ︙ |