Skip to content

Instantly share code, notes, and snippets.

@NickBaynham
Created March 3, 2020 15:59
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save NickBaynham/65794e6134b74754871672765368e624 to your computer and use it in GitHub Desktop.
Save NickBaynham/65794e6134b74754871672765368e624 to your computer and use it in GitHub Desktop.
package selfHealingExamples.tests.registration;
import org.jsoup.Jsoup;
import org.jsoup.nodes.Document;
import org.testng.annotations.Test;
import static org.testng.AssertJUnit.assertEquals;
public class RegistrationJSOUP extends BaseTest {
@Test
public void TestRegistration() {
getDriver().get("http://localhost:7800/bootstrap1.html#");
final String HTML_SOURCE_CODE = getDriver().getPageSource();
Document document = Jsoup.parse(HTML_SOURCE_CODE);
int inputs = document.body().getElementsByTag("input").size();
assertEquals(7, inputs);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment