UMD style wrapper for built versions compatible with CommonJS, AMD, and browser

Made the compiled versions compatible with CommonJS, AMD, and browser via a UMD-like pattern. Added tests for exports.

I would have added tests for the functionality and exports of the built files as these are not currently tested but it appears they are not currently the same so i left them alone bar adding the module definitions stuff, as i'm not sure what your build process is and your reasons for not exposing some of the exports from the libs.

The mods serve my desire of wanting to use AMD without polluting globals via shimming though, so hope it helps anyway.

Cheers, Alec