public void NoDuplicateRealmId() { var realmIds = new HashSet <string>(); foreach (Realm realm in Realm.Values()) { Assert.DoesNotContain(realm.RealmId, realmIds); realmIds.Add(realm.RealmId); } }
public void ExistingRealmNotRegisteredAgain() { var realmsCount = Realm.Values().Length; Realm.Register(Realm.OC1.RealmId, Realm.OC1.SecondLevelDomain); Assert.Equal(realmsCount, Realm.Values().Length); var realm = Realm.ValueOf(Realm.OC1.RealmId); Assert.Equal(Realm.OC1.RealmId, realm.RealmId); Assert.Equal(Realm.OC1.SecondLevelDomain, realm.SecondLevelDomain); }