Files
habitica/test/sanity
Blade Barringer 81b7eeeb71 Common reorg (#8025)
* Re-organize common folder

* fix: Correct paths in tests

* fix: move new content to proper folder

* chore: Move audio folder to assets

* Move sprites to sprites assets directory

* Move css sprites to assets directory

* Split out readmes for common code and sprites

* Move images to assets directory

* Move destinatin of shared browserified file

* remove unused file

* move compiled js to client-old

* Fix karma tests

* fix: Correct paths for sprites
2016-09-16 17:18:07 +02:00
..

Sanity Tests

Babel Paths for Production Environment

In development, we transpile at server start. This allows us to work quickly while developing, but is not suitable for production. So, in production we transpile the server code before the app starts.

This system means that requiring any files from common/script in website/server/**/*.js must be done through the common/index.js module. In development, it'll pass through to the pre-transpiled files, but in production it'll point to the transpiled versions. If you try to require or import a file directly, it will error in production as the server doesn't know what to do with some es2015isms (such as the import statement).

This test just verifies that none of the files in the server code are calling the common files directly.