Differences From Artifact [38c5330f76]:
- File tests/OFStringTests.m — part of check-in [1c499f0728] at 2018-04-15 12:51:13 on branch trunk — Add handling of AmigaOS paths (user: js, size: 43792) [annotate] [blame] [check-ins using]
To Artifact [e81e35af26]:
- File
tests/OFStringTests.m
— part of check-in
[49cb6ada5f]
at
2018-04-22 23:42:20
on branch trunk
— Make all tests pass on AmigaOS 3
Note: There is still some weirdness in the compiler. Instead of
m68k-amigaos-gcc, you need to use m68k-amigaos-g++ as OBJC, as otherwise
exceptions don't work.Before running the tests, you need to run "stack 8192". (user: js, size: 43917) [annotate] [blame] [check-ins using]
︙ | ︙ | |||
874 875 876 877 878 879 880 | /* * These test numbers can be generated without rounding if we have IEEE * floating point numbers, thus we can use == on them. */ TEST(@"-[floatValue]", [C(@"\t-0.25 ") floatValue] == -0.25 && | | | > | | > | > > | 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 | /* * These test numbers can be generated without rounding if we have IEEE * floating point numbers, thus we can use == on them. */ TEST(@"-[floatValue]", [C(@"\t-0.25 ") floatValue] == -0.25 && [C(@"\r\n\tINF\t\n") floatValue] == INFINITY && [C(@"\r -INFINITY\n") floatValue] == -INFINITY && isnan([C(@" NAN\t\t") floatValue])) #if !defined(OF_ANDROID) && !defined(OF_SOLARIS) && !defined(OF_DJGPP) && \ !defined(OF_AMIGAOS3) # define INPUT @"\t-0x1.FFFFFFFFFFFFFP-1020 " # define EXPECTED -0x1.FFFFFFFFFFFFFP-1020 #else /* Android, Solaris, DJGPP and AmigaOS3 do not accept 0x for strtod() */ # if (!defined(OF_SOLARIS) || !defined(OF_X86)) && !defined(OF_AMIGAOS3) # define INPUT @"\t-0.123456789 " # define EXPECTED -0.123456789 # else /* * Solaris' strtod() has weird rounding on x86, but not on x86_64/ * AmigaOS 3 with libnix has weird rounding as well. */ # define INPUT @"\t-0.125 " # define EXPECTED -0.125 # endif #endif TEST(@"-[doubleValue]", [INPUT doubleValue] == EXPECTED && [C(@"\r\n\tINF\t\n") doubleValue] == INFINITY && |
︙ | ︙ |