Skip to main content

form

form [url] [selectorValuePairs] [submitSelector]

Populate a form based on selector/value pairs and invoke a click based on a selector. Captures cookieStorage, localStorage, and sessionStorage.

Example:

form http://localhost:2001 "[['#username','admin'],['#password','advanced']]" "input[type=submit]"

arguments:

url

The url of the form. (type: string)

selectorValuePairs

A stringified array of key value tuples containing a css selector and a form input value. (type: string)

submitSelector

The css selector of the submit element to click after form has been populated. (type: string)

flags:

--appendStage

Used to append the results from a previous stage to the current stage. (provide a label, stage index, or boolean true to append the previous results)

--attributes

A comma separated list of attributes to include in the command results. If not provided, all attributes will be included.

--cache

A boolean value of true/false that determines whether or not to use the cache. Generally most commands will default to true.

--filter

A filter to run on the command results before completing the command. If not provided, no filter is run on the results.

--fresh

Starts the stage as if it was a fresh query, so will not use any previous result.

--labelStage

Used to label a stage with a user provided label.

--stats

Controls if a stats calculation is run on a stage after it completes.