Clean up vector class.
Move unittests to more logically sound places
Add unittests for clearing functions.