public void IdentityPermissions_NoModulePermissions()
        {
            identityPermissions = new IdentityPermissions(true, null, agencyModulePermissions);
            Assert.IsNotNull(identityPermissions);
            Mock <IModulePermissions> modulePermission = new Mock <IModulePermissions>();

            modulePermission.SetupGet(a => a.CanDelete).Returns(true);
            var canAccessModule = identityPermissions.HasModulePermissions(Utils.agencyId, ModuleType.Arrest, modulePermission.Object);

            Assert.IsFalse(canAccessModule);
        }
        public void IdentityPermissions_DeleteHasModulePermissions()
        {
            agencyModulePermissions = new Dictionary <Guid, Dictionary <ModuleType, IModulePermissions> >();
            Mock <IModulePermissions> modulePermission = new Mock <IModulePermissions>();

            modulePermission.SetupGet(a => a.CanDelete).Returns(true);

            var modulePermissions = new Dictionary <ModuleType, IModulePermissions>();

            modulePermissions.Add(ModuleType.Arrest, modulePermission.Object);

            agencyModulePermissions.Add(Utils.agencyId, modulePermissions);

            identityPermissions = new IdentityPermissions(true, null, agencyModulePermissions);
            Assert.IsNotNull(identityPermissions);
            var canAccessModule = identityPermissions.HasModulePermissions(Utils.agencyId, ModuleType.Arrest, modulePermission.Object);

            Assert.IsTrue(canAccessModule);
        }