From: Dennis Ranke Date: 2003-12-24T03:36:53+09:00 Subject: Re: Ruby 1.8.1 preview4 On Tue, 23 Dec 2003 11:55:06 +0900, NAKAMURA, Hiroshi wrote: >> On a Playstation2 running linux: > > Thanks. Very interesting. Seems to be 3 kind of errors. > > > [1, 2, 31, 32; floating point] > >> 1) Failure: >> test_SOAPDouble(SOAP::TestSOAP) [./soap/test_basetype.rb:257]: >> <"-0"> expected but was >> <"+0">. > > How does this dump? > $ ruby -e 'a = -0.0; p (1 / a > 0.0)' > > expecting false.. irb(main):002:0> VERSION => "1.8.1" irb(main):001:0> a=-0.0 => 0.0 irb(main):002:0> 1 / a > 0.0 => true irb(main):003:0> 1 / a => Infinity >> 2) Failure: >> test_SOAPFloat(SOAP::TestSOAP) >> [./soap/test_basetype.rb:161:in `test_SOAPFloat' >> ./soap/test_basetype.rb:160:in `each' >> ./soap/test_basetype.rb:160:in `test_SOAPFloat']: >> <1.4e-45> expected but was >> <0.0>. > > Hmm... ok, my theory about single-precision floats was probably wrong: irb(main):009:0> 1.0/2**256 => 8.63616855509444e-78 So as long as SOAP doesn't convert between different float representations, i have no idea where this error comes from. > [3-9, 28-30; socket] >> 3) Error: >> test_charset(SOAP::TestStreamHandler): >> SocketError: getaddrinfo: Temporary failure in name resolution > > $ ruby -rsocket -e 'p Socket.getaddrinfo("localhost", "http")' > > Same error? Yes, and "unknown host" with "ping localhost", so i added localhost to my hosts file, which got rid of those errors... ;) > [10 - 27; strscan] >> test_s_mustc(TestStringScanner) [./strscan/test_stringscanner.rb:43]: >> Exception raised: >> Class: >> Message: <"strscan is not C version"> >> ---Backtrace--- >> /usr/local/lib/ruby/site_ruby/1.8/rscan.rb:18:in `must_C_version' >> ../strscan/test_stringscanner.rb:44:in `test_s_mustc' >> ../strscan/test_stringscanner.rb:43:in `assert_nothing_raised' >> ../strscan/test_stringscanner.rb:43:in `test_s_mustc' >> --------------- > > Delete /usr/local/lib/ruby/site_ruby/1.8/rscan.rb and strscan related > file > (/usr/local/lib/ruby/site_ruby/1.8/i686-linux/* or something). > Would you please try it again then? Ok, now only the four float errors are left: Loaded suite . Started ..................................................................................................................................................................................................................................................................................................................................................................................................................F.F..................basic_auth is not supported under soap4r + net/http for now. ........................................................................................................................................................................................................................................F.F.................................................................... Finished in 271.976239 seconds. 1) Failure: test_SOAPDouble(SOAP::TestSOAP) [./soap/test_basetype.rb:257]: <"-0"> expected but was <"+0">. 2) Failure: test_SOAPFloat(SOAP::TestSOAP) [./soap/test_basetype.rb:161:in `test_SOAPFloat' ./soap/test_basetype.rb:160:in `each' ./soap/test_basetype.rb:160:in `test_SOAPFloat']: <1.4e-45> expected but was <0.0>. 3) Failure: test_XSDDouble(XSD::TestXSD) [./xsd/test_xsd.rb:290]: <"-0"> expected but was <"+0">. 4) Failure: test_XSDFloat(XSD::TestXSD) [./xsd/test_xsd.rb:194:in `test_XSDFloat' ./xsd/test_xsd.rb:193:in `each' ./xsd/test_xsd.rb:193:in `test_XSDFloat']: <1.4e-45> expected but was <0.0>. 724 tests, 7262 assertions, 4 failures, 0 errors -- exoticorn/farbrausch