unit testing and reorganization

order between attributes, constructor and other methods
int =>Integer
Unit testing
Massive overhaul