Create a definitions folder

Move test.js to tm.gallery.js
This file contains integration tests for the code
and will be used to generate the actual source code
by compiling the loaded source code