Improved efficiency of undeployApps method.
Added test file to try out scripts