示例#1
0
        public static DeviceYamlTestCase ReadFromMap(Dictionary <string, string> map)
        {
            DeviceYamlTestCase tc = new DeviceYamlTestCase()
            {
                UserAgent = map["user_agent_string"],
                Family    = map["family"],
            };

            return(tc);
        }
    public static DeviceYamlTestCase ReadFromMap(Dictionary<string, string> map)
    {
      DeviceYamlTestCase tc = new DeviceYamlTestCase()
      {
        UserAgent = map["user_agent_string"],
        Family = map["family"],

      };
      return tc;
    }
        public static DeviceYamlTestCase ReadFromMap(Dictionary<string, string> map)
        {
            DeviceYamlTestCase tc = new DeviceYamlTestCase()
              {
            UserAgent = map["user_agent_string"],
            Family = map["family"],
            IsMobile = map["is_mobile"] == "True",
            IsSpider = map["is_spider"] == "True",

              };
              return tc;
        }
示例#4
0
        public static DeviceYamlTestCase ReadFromMap(Dictionary <string, string> map)
        {
            DeviceYamlTestCase tc = new DeviceYamlTestCase()
            {
                UserAgent = map["user_agent_string"],
                Family    = map["family"],
                IsMobile  = map["is_mobile"] == "True",
                IsSpider  = map["is_spider"] == "True",
            };

            return(tc);
        }
示例#5
0
 public void can_run_device_tests()
 {
     RunTests <DeviceYamlTestCase>(
         "UAParser.Tests.TestResources.test_device.yaml",
         configMap => DeviceYamlTestCase.ReadFromMap(configMap));
 }