More test coverage for configure package, fix a couple of bugs