change some uses of fail_unless to assert_eq