test for rect
javadoc, cleaning, tests