public void TestConstructionWithUri()
        {
            Uri uri = new Uri("http://www.google.com/");
            WebTestRequest request = new WebTestRequest(uri);

            Assert.IsNotNull(request);
        }
 public override IEnumerator<WebTestRequest> GetRequestEnumerator()
 {
     WebTestRequest request1 = new WebTestRequest("http://oreilly.com/");
     ValidateFormField rule1 = new ValidateFormField();
     rule1.Name = "q";
     rule1.ExpectedValue = String.Empty;
     request1.ValidateResponse += new WebTestRequest.ValidationEventHandler(rule1.Validate);
     yield return request1;
 }
        public override IEnumerator<WebTestRequest> GetRequestEnumerator()
        {
            ValidateResponseUrl rule1 = new ValidateResponseUrl();
            rule1.ExpectedResponseUrl = "http://phyer.net/phyle-box/index.php";

            WebTestRequest request1 = new WebTestRequest("http://phyer.net/phyle-box/index.php");
            request1.ValidateResponse += new WebTestRequest.ValidationEventHandler(rule1.Validate);
            yield return request1;
        }
        static void Main(string[] args)
        {
            WebTestRequest request = new WebTestRequest("http://www.vehix.com/");
            ExtractHiddenFields extractionRule1 = new ExtractHiddenFields();

            request.ExtractValues += new WebTestRequest.ExtractionEventHandler(extractionRule1.Extract);

            request.Execute();

            Debug.Assert(request.Context.Count > 0);
        }
 public void TestConstructionWithBadUrl()
 {
     WebTestRequest request = new WebTestRequest("www.google.com");
 }
        public void TestConstruction()
        {
            WebTestRequest request = new WebTestRequest("http://www.google.com/");

            Assert.IsNotNull(request);
        }