public void the_checkpoint_loads_without_errors_if_stored_data_count_is_less_than_best_count()
 {
     using (var checkpoint = new FileMultiCheckpoint(Filename, 10))
     {
         long check;
         Assert.IsTrue(checkpoint.TryGetMinMax(out check));
         Assert.AreEqual(1000, check);
     }
 }
 public void the_checkpoint_contains_all_previously_stored_data()
 {
     using (var checkpoint = new FileMultiCheckpoint(Filename, 3))
     {
         long check;
         Assert.IsTrue(checkpoint.TryGetMinMax(out check));
         Assert.AreEqual(1000, check);
     }
 }
 public void the_checkpoint_loads_and_processed_all_stored_data_even_if_best_count_is_smaller_now()
 {
     using (var checkpoint = new FileMultiCheckpoint(Filename, 2))
     {
         long check;
         Assert.IsTrue(checkpoint.TryGetMinMax(out check));
         Assert.AreEqual(2000, check);
     }
 }
Exemplo n.º 4
0
        public void should_not_return_checkpoint_when_empty()
        {
            long checkpoint;

            Assert.IsFalse(_checkpoint.TryGetMinMax(out checkpoint));
            Assert.AreEqual(0, checkpoint);
        }