public void Should_be_the_same()
        {
            var instance1 = new RequireRolePolicy("Editor");
            var instance2 = new RequireRolePolicy("Editor");
            Assert.That(instance1.GetHashCode(), Is.EqualTo(instance2.GetHashCode()));

            var instance3 = new RequireRolePolicy(UserRole.Writer);
            var instance4 = new RequireRolePolicy(UserRole.Writer);
            Assert.That(instance3.GetHashCode(), Is.EqualTo(instance4.GetHashCode()));
        }
        public void Should_not_be_the_same_when_roles_differ()
        {
            var instance1 = new RequireRolePolicy("Editor");
            var instance2 = new RequireRolePolicy("Writer");
            Assert.That(instance1.GetHashCode(), Is.Not.EqualTo(instance2.GetHashCode()));

            var instance3 = new RequireRolePolicy(UserRole.Publisher);
            var instance4 = new RequireRolePolicy(UserRole.Owner);
            Assert.That(instance3.GetHashCode(), Is.Not.EqualTo(instance4.GetHashCode()));
        }
 public void Should_not_be_the_same_when_types_differ()
 {
     var instance1 = new RequireAllRolesPolicy("Editor", "Writer");
     var instance2 = new RequireRolePolicy("Editor", "Writer");
     Assert.That(instance1.GetHashCode(), Is.Not.EqualTo(instance2.GetHashCode()));
 }