Escape bundler only if it's defined

@bfulton @adamjt 

If bundler isn't being used, no need to use the clean environment.
Added the CLI test similar to aerosol