Fix unit tests, move UserPermissionMixin to mixins folder and AjaxPromise to utils folder