moved resolveSpec to compile. Added missing method from last commit. fixed misscalled methods from merge
updated tests for changes. Removed test() method, doesn't really make sense with this module.