Restructuring packages to make it testable.
Add basic test for connection specification.