describe('Test person avatar menu', function () { 'use strict'; var compile, scope, $httpBackend, timeout; beforeEach(module('myitsmApp', 'templates')); beforeEach(function () { inject(function ($compile, $rootScope, $injector, $timeout) { $httpBackend = $injector.get('$httpBackend'); var getLocale = function () { return readJSON('scripts/app/i18n/resources-locale_en.json'); }; $httpBackend.whenGET(/^scripts\/app\/i18n\/resources-locale_en.*$/).respond(getLocale()); $httpBackend.whenGET('/smartit/rest/serverstates').respond(200); $httpBackend.whenGET('/smartit/rest/sessionstatus?getLicenseKey=true').respond(200); compile = $compile; scope = $rootScope.$new(); timeout = $timeout; }); }); function getCompiledElement(address) { var compiledElement = compile(angular.element('