fix unit test
fix byte range inconsistency between Java/Go