Filter Info > Filter Kind > Variables

This is the list of variables added for filters. Variables are markers in the text that are replaced by another value when the filter is used. The variable name should not contain any spaces, and should be enclosed by braces, e.g. {TestName}. They are used by the Script and other filter plug-ins, and will be available for relevant future plug-ins too.

Filters inherit the variables from the service, and add several extra with the results of the service (with a Service prefix) and any previous filters (with a Filter prefix). Of particular interest is the {FilterInputText} variable, which is set to whatever is chosen for the Input when adding the filters in the Filters page of the Test Info pane.

Note also that numbers can be inserted after the "Filter" prefix to refer to values of previous filters, e.g. a later filter can refer to the previous text of the first filter via {Filter1PreviousText}, or the error of the second filter via {Filter2Error}. Alternatively, filter variables can be referred to relative to the current filter by inserting Prior and a number, e.g. the input text of the prior filter can be obtained via {FilterPrior1InputText}.

Variable:Outputs:
FilterCountNumber of filters for this test.
FilterDateDate that the current filter was started, in the form YYYY-MM-DD.
FilterErrorError message from the previous filter (or service if no previous filter).
FilterForChangedIndicates if the current filter is used when the current status is Changed: yes or no.
FilterForFailureIndicates if the current filter is used when the current status is Failure: yes or no.
FilterForSuccessIndicates if the current filter is used when the current status is success (i.e. Unchanged or Changed): yes or no.
FilterForUnchangedIndicates if the current filter is used when the current status is Unchanged: yes or no.
FilterIndex1-based sequence number of the current filter.
FilterInputTextText from the variable selected for the Input in the test's filter configuration.
FilterInputVariableName of the variable selected for the Input in the test's filter configuration.
FilterKindName of the plug-in used for the current filter.
FilterLookForChangesIndicates if the current filter will detect changes: yes or no.
FilterNameName of the current filter.
FilterOutputTextOutput text from the previous filter (or equivalent to the input text if no previous filter).
FilterPreviousTextOutput text from the last time this filter was used with this test. This is used with the change detection feature.
FilterStatusNumberStatus of the previous filter (or service if no previous filter), in numeric form. 0 = Unchanged, 1 = Changed, 2 = Failure.
FilterStatusTypeStatus of the previous filter (or service if no previous filter): Unchanged, Changed or Failure.
FilterTimeTime that the current filter was started, in the form HH:MM:SS.
FilterUseTestControlsIndicates if the current filter includes controls in the test editor: yes or no.
ServiceContentLengthSize in bytes of the service output.
ServiceContentTypeContent type of the service output, e.g. "text/html" or "text/plain".
ServiceErrorError from the service, if a failure, or blank if successful.
ServiceHeaderTextHeader text output by the service. Often blank, except where meaningful, e.g. HTTP headers.
ServiceRequestTextSummary of the service's request, e.g. the URL, script, or other value.
ServiceResponseTextText output by the service, e.g. HTML source or a script output.
ServiceResultCodeCode result from the service, e.g. "OK" or "404".
ServiceStatusNumberStatus of the service, in numeric form. 0 = Unchanged, 1 = Changed, 2 = Failure.
ServiceStatusTypeStatus of the service: Success or Failure.
ServiceTitleDisplay title for the service, e.g. as used in the Preview window.