added missing / updated tests
added lots of javadocs
fixed unique() modifying ends of ranges