public final class InputSpecification extends Object
Name: <input type="text" id="name" /><br />
Phone: <input name="phone" /><br />
Mobile: <input name="mobile" /><br />
Agree to licence: <input id="agreelicence" type="checkbox" /><br />
Other:content
JAVA:
InputSpecification input = new InputSpecification();
//for fields with text
input.field("name").setValue("John Doe");
input.field("phone", "mobile").setValue("1234567890");
//for checkboxes
input.field("agreelicence").setValue(true);
Crawljax will set Name, Phone, Mobile, and Agree values. It will enter a random string in the
Other field if enabled in CrawljaxConfiguration| Constructor and Description |
|---|
InputSpecification() |
| Modifier and Type | Method and Description |
|---|---|
com.google.common.collect.ImmutableList<CrawlElement> |
getCrawlElements() |
Map<Identification,FormInput> |
getFormInputs() |
com.google.common.collect.ImmutableList<Form> |
getForms() |
FormInput |
inputField(FormInput.InputType type,
Identification identification) |
FormInput |
inputField(FormInput input) |
FormAction |
setValuesInForm(Form form)
Links the form with an HTML element which can be clicked.
|
public FormInput inputField(FormInput.InputType type, Identification identification)
public Map<Identification,FormInput> getFormInputs()
public FormAction setValuesInForm(Form form)
form - the collection of the input fieldsFormpublic com.google.common.collect.ImmutableList<Form> getForms()
public com.google.common.collect.ImmutableList<CrawlElement> getCrawlElements()
Copyright © 2007–2019. All rights reserved.