public AddEncryptionSupportToClientsMigrationStepTests(MongoSetup mongoSetup)
     : base(mongoSetup)
 {
     _settings = new MongoDbClientStoreSettings {
         CollectionName             = "clients",
         SharedSecretEncryptionKey  = new SharedSecretEncryptionKey("The_Big_Secret"),
         ConnectionString           = "dummy",
         ClientCacheEntryExpiration = TimeSpan.Zero
     };
     _sut = new AddEncryptionSupportToClientsMigrationStep(new MongoDatabaseClientProvider(Database), _settings);
 }
コード例 #2
0
        public AddEncryptionSupportToClientsMigrationStepTests(MongoSetup mongoSetup)
            : base(mongoSetup)
        {
            FakeFactory.Create(out _stringProtectorFactory);
            A.CallTo(() => _stringProtectorFactory.CreateSymmetric(A <string> ._))
            .Returns(new FakeStringProtector());

            _settings = new MongoDbClientStoreSettings {
                CollectionName             = "clients",
                SharedSecretEncryptionKey  = new SharedSecretEncryptionKey("The_Big_Secret"),
                ConnectionString           = "dummy",
                ClientCacheEntryExpiration = TimeSpan.Zero
            };
            _sut = new AddEncryptionSupportToClientsMigrationStep(
                new MongoDatabaseClientProvider(Database),
                _settings,
                _stringProtectorFactory);
        }