Fix and test lrange