Exemple #1
0
        public void ProteinBenchmarkDataContainer_Read_FromDisk()
        {
            // Arrange
            var container = new ProteinBenchmarkDataContainer
            {
                FilePath = Path.Combine("TestFiles", ProteinBenchmarkDataContainer.DefaultFileName)
            };

            // Act
            container.Read();
            // Assert
            Assert.AreEqual(692, container.Data.Count);
        }
Exemple #2
0
 public void ProteinBenchmarkDataContainer_Write_ToDisk()
 {
     // Arrange
     using (var artifacts = new ArtifactFolder())
     {
         var collection = new ProteinBenchmarkDataContainer
         {
             FilePath = artifacts.GetRandomFilePath(), Data = CreateTestBenchmarkData(),
         };
         // Act
         collection.Write();
         // Assert
         // clear the data and read it
         collection.Data = null;
         collection.Read();
         ValidateTestBenchmarkData(collection.Data);
     }
 }