fixed what I've messed up with "moment" in English :(
Merge pull request #730 from leider/hotfix

fixed what I've messed up with "moment" in English :(
Inline local variable.
Extracted app creation so that it is only done once for each required app.
Changed the last "un-exceptioned" function of the testpersistence to throw an exception. Added a stub for persistence where it was required.