Closed ykolomiets closed 6 years ago
Yes, best way is decomposing all reusable functions and classes into libraries and place them to applications/<name>/lib/<module>.js
exporting everything to api
. In this case testing will not be a problem, you can just require those modules to your tests so you can call everything without impress or prepare integration tests with impress, accessing your internal API with http/ws/jstp.
@tshemsedinov, thanks! What is the difference between /applications/test/setup and /application/test/init? What is the main purpose of /application/test/model? Is there any documentation?
/setup
is a place to for initial setup and migration scripts. /init
scripts executes on app server startup. You do not need /model
, in future it will be a place to hold subject-domain model schemas.
Hi, again) I have a question about structuring our application What is the best approach you recommend to use for stateful impress-server? I need some classes User, FightSession, some DAOs. Where can I place them? In application/test/lib and assign them as properties on global object
api
? How can I test my code?