public void ReadTokenFromStore_EmptyStore_ReturnsNull()
        {
            var s = new SqlServerSessionSecurityTokenStore {
                ConnectionStringName = ConnectionStringName
            };
            var token = CreateToken(DateTime.UtcNow, TimeSpan.FromHours(8));
            var key   = CreateKeyFromToken(token);

            var tokenTuple = s.ReadTokenFromStore(key);

            tokenTuple.Should().BeNull();
        }
        public void UpdateTokenInStore_EmptyStore_CanBeReadBack()
        {
            var s = new SqlServerSessionSecurityTokenStore {
                ConnectionStringName = ConnectionStringName
            };
            var token = CreateToken(DateTime.UtcNow, TimeSpan.FromHours(8));
            var key   = CreateKeyFromToken(token);

            s.UpdateTokenInStore(key, token, token.KeyExpirationTime);
            var roundTrippedTokenTuple = s.ReadTokenFromStore(key);

            roundTrippedTokenTuple.Should().NotBeNull();
            roundTrippedTokenTuple.Item2.ShouldBeEquivalentTo(token);
        }