add tests for initApp
Merge pull request #321 from lusini/add-tests-for-initApp-middleware

Add tests for initApp middleware