public static OSYamlTestCase ReadFromMap(Dictionary<string, string> map)
 {
   OSYamlTestCase tc = new OSYamlTestCase()
   {
     UserAgent = map["user_agent_string"],
     Family = map["family"],
     Major = map["major"],
     Minor = map["minor"],
     Patch = map["patch"],
     PatchMinor = map["patch_minor"]
   };
   return tc;
 }
Beispiel #2
0
        public static OSYamlTestCase ReadFromMap(Dictionary <string, string> map)
        {
            OSYamlTestCase tc = new OSYamlTestCase()
            {
                UserAgent  = map["user_agent_string"],
                Family     = map["family"],
                Major      = map["major"],
                Minor      = map["minor"],
                Patch      = map["patch"],
                PatchMinor = map["patch_minor"]
            };

            return(tc);
        }
 public void can_run_user_agent_parser_os_tests()
 {
     RunTests <OSYamlTestCase>(
         "UAParser.Tests.TestResources.test_user_agent_parser_os.yaml",
         configMap => OSYamlTestCase.ReadFromMap(configMap));
 }
 public void can_run_additional_os_tests()
 {
     RunTests <OSYamlTestCase>(
         "UAParser.Tests.TestResources.additional_os_tests.yaml",
         configMap => OSYamlTestCase.ReadFromMap(configMap));
 }