BTDBTest.KeyValueDBTest.AddingContinueToSameFileAfterReopenOfDBWith2TransactionLogFiles C# (CSharp) Method

AddingContinueToSameFileAfterReopenOfDBWith2TransactionLogFiles() private method

        public void AddingContinueToSameFileAfterReopenOfDBWith2TransactionLogFiles()
        {
            using (var fileCollection = new InMemoryFileCollection())
            {
                using (IKeyValueDB db = new KeyValueDB(fileCollection, new NoCompressionStrategy(), 1024))
                {
                    using (var tr = db.StartTransaction())
                    {
                        tr.CreateOrUpdateKeyValue(_key1, new byte[1024]);
                        tr.CreateOrUpdateKeyValue(Key2, new byte[10]);
                        tr.Commit();
                    }
                }
                Assert.Equal(2u, fileCollection.GetCount());
                using (IKeyValueDB db = new KeyValueDB(fileCollection, new NoCompressionStrategy(), 1024))
                {
                    using (var tr = db.StartTransaction())
                    {
                        tr.CreateOrUpdateKeyValue(Key2, new byte[1024]);
                        tr.CreateOrUpdateKeyValue(_key3, new byte[10]);
                        tr.Commit();
                    }
                }
                Assert.Equal(4u, fileCollection.GetCount());
                using (IKeyValueDB db = new KeyValueDB(fileCollection, new NoCompressionStrategy(), 1024))
                {
                    using (var tr = db.StartTransaction())
                    {
                        tr.CreateOrUpdateKeyValue(Key2, Key2);
                        tr.Commit();
                    }
                }
                Assert.Equal(4u, fileCollection.GetCount());
            }
        }