Backport tests to rustc 64b990d 2014-06-26