Adding tests and changing the package structure