Exposes loaded modules as globals.require.modules
Renames exposed require modules to require.cache
Merge pull request #577 from benjamincox/topics/exposemodules

Exposes loaded modules as globals.require.modules for testing convenience