Example #1
0
        public void ProfilesTest()
        {
            using (Tokenio.User.TokenClient tokenClient = TestUtil.CreateClient())
            {
                UserMember member  = tokenClient.CreateMemberBlocking(TestUtil.RandomAlias());
                Profile    profile = MemberMethodsSample.Profiles(member);

                Assert.NotEmpty(profile.DisplayNameFirst);
            }
        }
Example #2
0
        public void KeysTest()
        {
            using (Tokenio.User.TokenClient tokenClient = TestUtil.CreateClient())
            {
                IKeyStore     keyStore     = new InMemoryKeyStore();
                ICryptoEngine cryptoEngine = new TokenCryptoEngine("member-id", keyStore);

                UserMember member = tokenClient.CreateMemberBlocking(TestUtil.RandomAlias());
                MemberMethodsSample.Keys(cryptoEngine, member);
            }
        }
Example #3
0
        public void AliasesTest()
        {
            using (Tokenio.User.TokenClient tokenClient = TestUtil.CreateClient())
            {
                UserMember member = tokenClient.CreateMemberBlocking(TestUtil.RandomAlias());
                MemberMethodsSample.Aliases(tokenClient, member);
                List <Alias> aliases = member.GetAliasesBlocking().ToList();

                Assert.Equal(1, aliases.Count);
                Assert.Contains("alias4", aliases[0].Value);
            }
        }