Fix unit test: Nashorn returns a double after incrementing, not an integer