Sam Ruby wrote: > > I'm also seeing other > oddities with encodings that I will try to build a more focused test > case for. I'm giving up building a smaller test case for the moment. The symptoms are rather odd, and literally takes only ten seconds to recreate -- including the downloads. svn checkout -r 110 http://builder.rubyforge.org/svn/trunk/ builder wget http://intertwingly.net/stories/2008/01/04/builder5.diff cd builder patch -p 0 < ../builder5.diff export RUBYLIB=lib rake test_all # 101 tests, 173 assertions, 0 failures, 0 errors mv test/test_xchar.rb test/test_xchar.save sed -e 's/force_encoding.*/force_encoding(Encoding.find("BINARY"))/' < test/test_xchar.save > test/test_xchar.rb rake test_all # ArgumentError: unknown encoding name - BINARY rm test/test_markupbuilder.rb rm test/test_eventbuilder.rb rake test_all # 30 tests, 39 assertions, 0 failures, 0 errors What's going on here is that I have a patch that makes builder pass its unit test suite on Ruby 1.9, but if I change one line to find the encoding named 'BINARY' later on in the run, it fails, even though it was able to find this alias for the encoding earlier in the run. If I then remove some unrelated tests (both sets need to be removed, removing just one isn't sufficient), and the tests pass again. Also of note: while finding the 'BINARY' encoding fails, finding 'ASCII-8BIT' succeeds. This test passes on revision 15007 of ruby, but not on revision 15047. - Sam Ruby