OpenVeo test API

API Docs for: 8.0.0
Show:

MatchTextField

Extends TextField
Module: e2e

Summary

Defines a MatchTextField.

A MatchTextField is a field part of a match, it is pretty much like a TextField except that it is part of a match.

Constructor

MatchTextField

Syntax

MatchTextField

(
  • conf
)

Summary

Parameters:

  • conf Object

    Field configuration

    • name String

      Field configuration

    • baseElement ElementFinder

      The match element

Methods

clear

Inherited from Field but overwritten in lib/e2e/fields/TextField.js:100

Syntax

clear

() Promise

Summary

Clears field value.

Returns:

Promise:
Promise resolving when the field is cleared

Example:

myField.clear().then(function() {
  console.log('Field cleared');
});

getDescription

Syntax

getDescription

() Promise

Summary

Gets field description.

Returns:

Promise:

Promise resolving with the description

Example:

myField.getDescription().then(function(description) {
  console.log('Field description is : ' + description);
});

getElement

Inherited from Field but overwritten in lib/e2e/fields/MatchField.js:70

Syntax

getElement

() Promise

Summary

Gets match text field element wrapper.

Returns:

Promise:

Promise resolving with the element

getErrorMessage

Syntax

getErrorMessage

() Promise

Summary

Gets field error message.

Returns:

Promise:

Promise resolving with the error message

Example:

myField.getErrorMessage().then(function(errorMessage) {
  console.log('Error message : ' + errorMessage);
});

getLabel

Syntax

getLabel

() Promise

Summary

Gets field label.

Returns:

Promise:

Promise resolving with the label

Example:

myField.getLabel().then(function(label) {
  console.log('Field label is : ' + label);
});

getText

Syntax

getText

() Promise

Summary

Gets field text representation in case of an inline editable field.

Returns:

Promise:

Promise resolving with field text representation

Example:

myField.getText().then(function(text) {
  console.log(text);
});

getValue

Inherited from Field but overwritten in lib/e2e/fields/TextField.js:51

Syntax

getValue

() Promise

Summary

Gets field value.

Returns:

Promise:
Promise resolving with field value

Example:

myField.getValue().then(function(value) {
  console.log('Got value : ' + value);
});

isOnError

Inherited from Field but overwritten in lib/e2e/fields/TextField.js:121

Syntax

isOnError

() Promise

Summary

Tests if a field is considered as on error.

Returns:

Promise:
Promise resolving with a boolean indicating if the field is on error

Example:

myField.isOnError().then(function(isOnError) {
  console.log('Is field on error ? ' + isOnError);
});

setValue

Inherited from Field but overwritten in lib/e2e/fields/TextField.js:72

Syntax

setValue

(
  • [value='']
)
Promise

Summary

Sets field value.

Parameters:

  • [value=''] String optional
    Field's value

Returns:

Promise:
Promise resolving when the field is filled

Example:

myField.setValue('new value').then(function() {
  console.log('Value set');
});

Properties

baseElement

Syntax

baseElement

ElementFinder final

Summary

Element from where to look for the field (typically the form element).

fieldTag

Syntax

fieldTag

ElementFinder

Summary

Tag name of the text field.

Default: "input"

name

Syntax

name

String final

Summary

Field label.