diff --git a/BenchtopParser/ProgramConfig.cs b/BenchtopParser/ProgramConfig.cs index 71d685a..1f1c2d9 100644 --- a/BenchtopParser/ProgramConfig.cs +++ b/BenchtopParser/ProgramConfig.cs @@ -1,5 +1,6 @@ using System; using System.Collections.Generic; +using System.Dynamic; using System.Linq; using System.Text; using System.Threading.Tasks; diff --git a/BenchtopParserTests/I28_Program_Config_Tests.cs b/BenchtopParserTests/Program_Config_Tests.cs similarity index 83% rename from BenchtopParserTests/I28_Program_Config_Tests.cs rename to BenchtopParserTests/Program_Config_Tests.cs index 7853358..5319204 100644 --- a/BenchtopParserTests/I28_Program_Config_Tests.cs +++ b/BenchtopParserTests/Program_Config_Tests.cs @@ -1,15 +1,17 @@ namespace BenchtopParserTests { - public class I28_Program_Config_Tests { + public class Program_Config_Tests { + public String program_config_value; + [SetUp] public void Setup() { + program_config_value = File.ReadAllText( + Path.Combine(TestContext.CurrentContext.TestDirectory, @"TestFiles\Program Config.txt") + ); } [Test] public void Test_ProgramConfig() { - String program_config = File.ReadAllText( - Path.Combine(TestContext.CurrentContext.TestDirectory, @"TestFiles\Program Config.txt") - ); - var programConfigs = BenchtopParser.I28.Load_ProgramConfig(program_config); + var programConfigs = BenchtopParser.I28.Load_ProgramConfig(program_config_value); Assert.IsNotNull(programConfigs); // Check that group collecting works - diff --git a/BenchtopParserTests/Transducer_Verify_Tests.cs b/BenchtopParserTests/Transducer_Verify_Tests.cs index 2fc9388..cda1da9 100644 --- a/BenchtopParserTests/Transducer_Verify_Tests.cs +++ b/BenchtopParserTests/Transducer_Verify_Tests.cs @@ -1,15 +1,16 @@ namespace BenchtopParserTests { public class Transducer_Verify_Tests { + public String transducer_verify_value; [SetUp] public void Setup() { + transducer_verify_value = File.ReadAllText( + Path.Combine(TestContext.CurrentContext.TestDirectory, @"TestFiles\Transducer Verify.txt") + ); } [Test] public void Test_TransducerVerify() { - String transducer_verify = File.ReadAllText( - Path.Combine(TestContext.CurrentContext.TestDirectory, @"TestFiles\Transducer Verify.txt") - ); - BenchtopParser.TransducerVerify tv = BenchtopParser.I28.Load_TransducerVerify(transducer_verify); + BenchtopParser.TransducerVerify tv = BenchtopParser.I28.Load_TransducerVerify(transducer_verify_value); Assert.That(tv.transducers[1].id, Is.EqualTo(1)); Assert.That(tv.transducers[1].name, Is.EqualTo("CTS D34-442 115PSIA")); }