More tests and some changes to signature
Restructuring