Fixed some test errors and make one test pass.