Beispiel #1
0
        public void GettingStarted()
        {
            dynamic zombie = new ZombieDriver();

            zombie.visit("http://www.google.com");
            zombie.fill("q", "zombie.js");
            zombie.click("input[value=Search]");

            zombie.assert.text("title", "zombie.js - Google Search");
            zombie.assert.text("#f", "Zombie by assaf - JS.ORG");
        }
Beispiel #2
0
        public void FormSubmission()
        {
            dynamic zombie = new ZombieDriver();
            zombie.waitDuration = "30s";

            zombie.visit("https://www.facebook.com");
            zombie.assert.text("title", "Facebook - Log In or Sign Up");

            zombie.fill("firstname", "Rick");
            zombie.fill("lastname", "Grimes");
            zombie.fill("input[type=password]", "SheriffR1ck");

            zombie.select("birthday_day", "14");
            zombie.select("birthday_month", "9");
            zombie.select("birthday_year", "1983");

            zombie.choose("Male");

            zombie.click("button[name=websubmit]");

            //  Validation error - Rick has no email address (due to the zombie apocolypse)
            zombie.assert.text("#reg_error_inner", "An error occurred. Please try again.");
        }