Skip to content

Tester

Tester object. Use it to perform assertions during test playback and output relevant information to the report. You do not need to record or learn this object, it is always automatically available in any test.

Property Summary

Property Description
Fail Test status, test failed.
Info Test status, test is neither passed nor failed.
Pass Test status, test passed.
Unresolved Test status, test status is unresolved, test terminated unexpectedly.

Action Summary

Action Description
AddImageToReport Adds image to the report.
Assert Checks if condition is 'true' and saves corresponding Report entry.
AssertContains Checks if str contains substr somewhere and saves corresponding Report entry.
AssertEndsWith Checks that str has substr in the end and saves corresponding Report entry.
AssertEqual Checks if obj1 equals to obj2 and saves corresponding Report entry.
AssertFalse Checks if val is false and saves corresponding Report entry.
AssertGreater Checks if n1 greater than n2 and saves corresponding Report entry.
AssertGreaterOrEqual Checks if n1 greater or equal than n2 and saves corresponding Report entry.
AssertImage Checks if 'img1' equals to image stored at 'path' and saves corresponding Report entry.
AssertLess Checks if n1 is less than n2 and saves corresponding Report entry.
AssertLessOrEqual Checks if n1 differs from n2 and saves corresponding Report entry.
AssertNotContains Checks that str does not contain substr anywhere and saves corresponding Report entry.
AssertNotEqual Checks if obj1 differs from obj2 and saves corresponding Report entry.
AssertNotNull Checks if val is NotNull and saves corresponding Report entry.
AssertNotSet Checks if val is not set (i.e.
AssertNull Checks if val is null and saves corresponding Report entry.
AssertSet Checks if val is set (i.e.
AssertStartsWith Checks if str begins with substr and saves corresponding Report entry.
BeginTest Marks beginning of a test with a given name.
CaptureDesktopImage Captures screenshot of the desktop and adds it to the report.
CaptureObjectImage Captures screenshot of an object and adds it to the report.
CaptureWindowImage Captures screenshot of an application window matched by title and class and adds it to the report.
DumpCmdArgsJson Dump node.json with all arguments.
EndTest Marks end of a currently executed test.
FailTest Stops test execution and sets it's status to failed.
GetParam Read parameter field passed into the Test function by field name.
GetReportAttribute Gets report attribute previously set by PushReportAttribute or SetReportAttribute.
GetTestName Returns name of the running test.
GetTestStatus Gets status of currently executed test.
IgnoreStatus

In IgnoreStatus mode the assertion status is always treated as "Info".

Message Saves corresponding Report message.
MessageBox Shows message box to user.
MessageBoxPrompt Shows message box with question to the user and checks if user presses "Yes" or "No".
PopReportAttribute Resets an attribute to its previous value.
PushReportAttribute

Maintains "stacked" attributes.

ResetReportAttribute Removes report attribute previously set by SetReportAttribute.
SetReportAttribute Set persistent attribute.
SoftAssert Is identical to Tester.Assert.
SoftAssertAll Fail test if there were any previous failures.
SoftAssertContains Checks if str contains substr somewhere and saves corresponding Report entry.
SoftAssertEndsWith Checks that str has substr in the end and saves corresponding Report entry.
SoftAssertEqual Checks if obj1 equals to obj2 and saves corresponding Report entry.
SoftAssertFalse Checks if val is false and saves corresponding Report entry.
SoftAssertGreater Checks if n1 greater than n2 and saves corresponding Report entry.
SoftAssertGreaterOrEqual Checks if n1 greater or equal than n2 and saves corresponding Report entry.
SoftAssertImage Checks if 'img1' equals to image stored at 'path' and saves corresponding Report entry.
SoftAssertLess Checks if n1 is less than n2 and saves corresponding Report entry.
SoftAssertLessOrEqual Checks if n1 differs from n2 and saves corresponding Report entry.
SoftAssertNotContains Checks that str does not contain substr anywhere and saves corresponding Report entry.
SoftAssertNotEqual Checks if obj1 differs from obj2 and saves corresponding Report entry.
SoftAssertNotNull Checks if val is NotNull and saves corresponding Report entry.
SoftAssertNotSet Checks if val is not set (i.e.
SoftAssertNull Checks if val is null and saves corresponding Report entry.
SoftAssertSet Checks if val is set (i.e.
SoftAssertStartsWith Checks if str begins with substr and saves corresponding Report entry.
SuppressReport In SuppressReport mode all assertions are ignored.

Property Detail

Fail

Test status, test failed. Constant, equal to 0.

Type: number

Info

Test status, test is neither passed nor failed. Constant, equal to -2.

Type: number

Pass

Test status, test passed. Constant, equal to 1.

Type: number

Unresolved

Test status, test status is unresolved, test terminated unexpectedly. Constant, equal to -1.

Type: number

Action Detail

AddImageToReport

Adds image to the report.

AddImageToReport(path, caption) 

Parameters:

Name Type Description
path string Path to an image
caption string Caption for the entry added to the report

Assert

Checks if condition is 'true' and saves corresponding Report entry. Assertion is an atomic piece of verification. Assertion may contain some additional data (links, images, comments) set via 'data' parameter.

Assert(message, condition, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report.
condition boolean If 'true' - assertion is considered passed.
data SeSReportLink | SeSReportText | SeSReportImage | object[] | string Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

AssertContains

Checks if str contains substr somewhere and saves corresponding Report entry. Assertion is an atomic piece of verification. Assertion may contain some additional data (links, images, comments) set via 'data' parameter.

AssertContains(message, str, substr, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report.
str string String to search in.
substr string Substring to find.
data SeSReportLink | SeSReportText | SeSReportImage | Object[] Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

AssertEndsWith

Checks that str has substr in the end and saves corresponding Report entry. Assertion is an atomic piece of verification. Assertion may contain some additional data (links, images, comments) set via 'data' parameter.

AssertEndsWith(message, str, substr, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report.
str string String to search in.
substr string Substring to find.
data SeSReportLink | SeSReportText | SeSReportImage | Object[] Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

AssertEqual

Checks if obj1 equals to obj2 and saves corresponding Report entry. Assertion is an atomic piece of verification. Assertion may contain some additional data (links, images, comments) set via 'data' parameter.

AssertEqual(message, obj1, obj2, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report.
obj1 object First object to compare.
obj2 object Second object to compare.
data SeSReportLink | SeSReportText | SeSReportImage | Object[] Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

AssertFalse

Checks if val is false and saves corresponding Report entry. Assertion is an atomic piece of verification. Assertion may contain some additional data (links, images, comments) set via 'data' parameter.

AssertFalse(message, n1, n2, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report.
n1 number
n2 number
data SeSReportLink | SeSReportText | SeSReportImage | Object[] Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

AssertGreater

Checks if n1 greater than n2 and saves corresponding Report entry. Assertion is an atomic piece of verification. Assertion may contain some additional data (links, images, comments) set via 'data' parameter.

AssertGreater(message, n1, n2, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report.
n1 number First value to compare.
n2 number Second value to compare.
data SeSReportLink | SeSReportText | SeSReportImage | Object[] Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

AssertGreaterOrEqual

Checks if n1 greater or equal than n2 and saves corresponding Report entry. Assertion is an atomic piece of verification. Assertion may contain some additional data (links, images, comments) set via 'data' parameter.

AssertGreaterOrEqual(message, n1, n2, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report.
n1 number First value to compare.
n2 number Second value to compare.
data SeSReportLink | SeSReportText | SeSReportImage | Object[] Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

AssertImage

Checks if 'img1' equals to image stored at 'path' and saves corresponding Report entry. Assertion is an atomic piece of verification. Assertion may contain some additional data (links, images, comments) set via 'data' parameter.

AssertImage(message, img1, path, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report.
img1 object ImageWrapper object (1st image to compare).
path string Path to the second image to compare.
data SeSReportLink | SeSReportText | SeSReportImage | Object[] Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

AssertLess

Checks if n1 is less than n2 and saves corresponding Report entry. Assertion is an atomic piece of verification. Assertion may contain some additional data (links, images, comments) set via 'data' parameter.

AssertLess(message, n1, n2, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report.
n1 number First value to compare.
n2 number Second value to compare.
data SeSReportLink | SeSReportText | SeSReportImage | Object[] Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

AssertLessOrEqual

Checks if n1 differs from n2 and saves corresponding Report entry. Assertion is an atomic piece of verification. Assertion may contain some additional data (links, images, comments) set via 'data' parameter.

AssertLessOrEqual(message, n1, n2, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report.
n1 object First value to compare.
n2 object Second value to compare.
data SeSReportLink | SeSReportText | SeSReportImage | Object[] Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

AssertNotContains

Checks that str does not contain substr anywhere and saves corresponding Report entry. Assertion is an atomic piece of verification. Assertion may contain some additional data (links, images, comments) set via 'data' parameter.

AssertNotContains(message, str, substr, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report.
str string String to search in.
substr string Substring to find.
data SeSReportLink | SeSReportText | SeSReportImage | Object[] Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

AssertNotEqual

Checks if obj1 differs from obj2 and saves corresponding Report entry. Assertion is an atomic piece of verification. Assertion may contain some additional data (links, images, comments) set via 'data' parameter.

AssertNotEqual(message, obj1, obj2, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report.
obj1 object First object to compare.
obj2 object Second object to compare.
data SeSReportLink | SeSReportText | SeSReportImage | Object[] Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

AssertNotNull

Checks if val is NotNull and saves corresponding Report entry. Assertion is an atomic piece of verification. Assertion may contain some additional data (links, images, comments) set via 'data' parameter.

AssertNotNull(message, n1, n2, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report.
n1 number
n2 number
data SeSReportLink | SeSReportText | SeSReportImage | Object[] Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

AssertNotSet

Checks if val is not set (i.e. it is null, 0, false or "") and saves corresponding Report entry. Assertion is an atomic piece of verification. Assertion may contain some additional data (links, images, comments) set via 'data' parameter.

AssertNotSet(message, n1, n2, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report.
n1 number
n2 number
data SeSReportLink | SeSReportText | SeSReportImage | Object[] Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

AssertNull

Checks if val is null and saves corresponding Report entry. Assertion is an atomic piece of verification. Assertion may contain some additional data (links, images, comments) set via 'data' parameter.

AssertNull(message, n1, n2, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report.
n1 number
n2 number
data SeSReportLink | SeSReportText | SeSReportImage | Object[] Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

AssertSet

Checks if val is set (i.e. not false, not 0, not null, not "") and saves corresponding Report entry. Assertion is an atomic piece of verification. Assertion may contain some additional data (links, images, comments) set via 'data' parameter.

AssertSet(message, n1, n2, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report.
n1 number
n2 number
data SeSReportLink | SeSReportText | SeSReportImage | Object[] Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

AssertStartsWith

Checks if str begins with substr and saves corresponding Report entry. Assertion is an atomic piece of verification. Assertion may contain some additional data (links, images, comments) set via 'data' parameter.

AssertStartsWith(message, str, substr, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report.
str string String to search in.
substr string Substring to find.
data SeSReportLink | SeSReportText | SeSReportImage | Object[] Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

BeginTest

Marks beginning of a test with a given name.

BeginTest(name, path, optionalParams) 

Parameters:

Name Type Description
name string Test name
path string Path to the test, that is executed. This string will be shown as a comment.
Optional.
optionalParams object Params to pass into Test(...) function.
Optional.

CaptureDesktopImage

Captures screenshot of the desktop and adds it to the report.

CaptureDesktopImage(caption) 

Parameters:

Name Type Description
caption string Image title for the report.

CaptureObjectImage

Captures screenshot of an object and adds it to the report.

CaptureObjectImage(caption, objId) 

Parameters:

Name Type Description
caption string Image title for the report.
objId objectId Id of an object or SeSObject instance.

CaptureWindowImage

Captures screenshot of an application window matched by title and class and adds it to the report.

CaptureWindowImage(caption, windowTitle, windowClass, bringToFront) 

Parameters:

Name Type Description
caption string Image title for the report.
windowTitle string String or regular expression to match window title.
windowClass string String or regular expression to match window class.
Optional, Default: "regex:.*".
bringToFront boolean Set to 'false' to not restore the window before making the image.
Optional, Default: "true".

DumpCmdArgsJson

Dump node.json with all arguments.

DumpCmdArgsJson(optNodeJsonPath, mkPackageJson) 

Parameters:

Name Type Description
optNodeJsonPath string node.json path
Optional.
mkPackageJson bool

EndTest

Marks end of a currently executed test. Calculates test results and performs finalization of test execution.

EndTest() 

FailTest

Stops test execution and sets it's status to failed.

FailTest(message, internal) 

Parameters:

Name Type Description
message string Failure description.
Optional, Default: "Test stopped on error".
internal

GetParam

Read parameter field passed into the Test function by field name.

GetParam(paramName, defaultValue) 

Parameters:

Name Type Description
paramName string
defaultValue string Default value

GetReportAttribute

Gets report attribute previously set by PushReportAttribute or SetReportAttribute.

GetReportAttribute(name) 

Parameters:

Name Type Description
name string Attribute name.

GetTestName

Returns name of the running test.

GetTestName() 

GetTestStatus

Gets status of currently executed test.

GetTestStatus() 

Returns:

One of: Tester.Info - test is neither passed nor failed; 1 - Tester.Pass - test passed; 0 - Tester.Fail - test failed; -1 - Tester.Unresolved - test status is unresolved, test terminated unexpectedly.

IgnoreStatus

In IgnoreStatus mode the assertion status is always treated as "Info". Real status is written to "realStatus" attribute in this case and used just for information purposes (i.e. it does not affect final test status).

This function is used when the test case needs to set test status manually.

  Tester.IgnoreStatus(true);
  Tester.Assert("Ignored Assertion", false); // This assertion is failed. But its status is ignored.
  Tester.IgnoreStatus(false);
  Tester.Assert("Test passed", true);
  // The overall test is passed because failed assertion is ignored.
IgnoreStatus(ignore) 

Parameters:

Name Type Description
ignore boolean Set to 'true' to report all messages but ignore the status (Pass/Fail)

Message

Saves corresponding Report message. Message may contain some additional data (links, images, comments) set via 'data' parameter.

Message(message, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report
data SeSReportLink | SeSReportText | SeSReportImage | Object[] Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

MessageBox

Shows message box to user. Use it for verbose and manual testing.

MessageBox(message) 

Parameters:

Name Type Description
message string Message to display.

MessageBoxPrompt

Shows message box with question to the user and checks if user presses "Yes" or "No". "Yes" => "Pass" goes to the report with this message. "No" => "Fail" is reported.

MessageBoxPrompt(question) 

Parameters:

Name Type Description
question string Question to display.

PopReportAttribute

Resets an attribute to its previous value. See PushReportAttribute for more information.

PopReportAttribute(name) 

Parameters:

Name Type Description
name string Attribute name to recall from stack.

Returns:

string: Previous value. Null if no such stacked attribute found.

PushReportAttribute

Maintains "stacked" attributes. Useful for nesting.


Example:


Main test sets scenario=Main. Then it calls another scenario (scenario Login) and then continues its own test actions.


We want all assertions to be attributed with current scenario name.

 function Main()
 {
     Tester.PushReportAttribute("scenario", "Main");
     Login();
     ...
     Tester.Assert("Main test passed", mainStatus); // Saved with scenario=Main
 }

function Login() { Tester.PushReportAttribute("scenario", "Login"); ... // Do login logic Tester.Assert("Login Result", loginStatus); Tester.PopReportAttribute("scenario"); // Set scenario value back to caller }

PushReportAttribute(name, value) 

Parameters:

Name Type Description
name string Attribute name to recall from stack.
value string New attribute value.

ResetReportAttribute

Removes report attribute previously set by SetReportAttribute.

ResetReportAttribute(name) 

Parameters:

Name Type Description
name string Attribute name.

SetReportAttribute

Set persistent attribute. It will be set for all subsequent report items (assertions, tests, requirements, and so on). It may be changed by calling the ResetReportAttribute function.

SetReportAttribute(name, value) 

Parameters:

Name Type Description
name string Attribute name to set.
value string New attribute value.

SoftAssert

Is identical to Tester.Assert. But when an assertion fails, don't stop execution and just record the failure. Later you may call Tester.SoftAssertAll(..) that will stop execution if at least one assertion failed.

SoftAssert(message, condition, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report.
condition boolean If 'true' - assertion is considered passed.
data SeSReportLink | SeSReportText | SeSReportImage | object[] | string Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

SoftAssertAll

Fail test if there were any previous failures. This method is designed to be used after one or many calls to Tester.SoftAssert(...).

SoftAssertAll(message) 

Parameters:

Name Type Description
message string Message to put in the report.

SoftAssertContains

Checks if str contains substr somewhere and saves corresponding Report entry. Assertion is an atomic piece of verification. Assertion may contain some additional data (links, images, comments) set via 'data' parameter.

SoftAssertContains(message, str, substr, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report.
str string String to search in.
substr string Substring to find.
data SeSReportLink | SeSReportText | SeSReportImage | Object[] Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

SoftAssertEndsWith

Checks that str has substr in the end and saves corresponding Report entry. Assertion is an atomic piece of verification. Assertion may contain some additional data (links, images, comments) set via 'data' parameter.

SoftAssertEndsWith(message, str, substr, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report.
str string String to search in.
substr string Substring to find.
data SeSReportLink | SeSReportText | SeSReportImage | Object[] Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

SoftAssertEqual

Checks if obj1 equals to obj2 and saves corresponding Report entry. Assertion is an atomic piece of verification. Assertion may contain some additional data (links, images, comments) set via 'data' parameter.

SoftAssertEqual(message, obj1, obj2, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report.
obj1 object First object to compare.
obj2 object Second object to compare.
data SeSReportLink | SeSReportText | SeSReportImage | Object[] Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

SoftAssertFalse

Checks if val is false and saves corresponding Report entry. Assertion is an atomic piece of verification. Assertion may contain some additional data (links, images, comments) set via 'data' parameter.

SoftAssertFalse(message, n1, n2, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report.
n1 number
n2 number
data SeSReportLink | SeSReportText | SeSReportImage | Object[] Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

SoftAssertGreater

Checks if n1 greater than n2 and saves corresponding Report entry. Assertion is an atomic piece of verification. Assertion may contain some additional data (links, images, comments) set via 'data' parameter.

SoftAssertGreater(message, n1, n2, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report.
n1 number First value to compare.
n2 number Second value to compare.
data SeSReportLink | SeSReportText | SeSReportImage | Object[] Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

SoftAssertGreaterOrEqual

Checks if n1 greater or equal than n2 and saves corresponding Report entry. Assertion is an atomic piece of verification. Assertion may contain some additional data (links, images, comments) set via 'data' parameter.

SoftAssertGreaterOrEqual(message, n1, n2, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report.
n1 number First value to compare.
n2 number Second value to compare.
data SeSReportLink | SeSReportText | SeSReportImage | Object[] Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

SoftAssertImage

Checks if 'img1' equals to image stored at 'path' and saves corresponding Report entry. Assertion is an atomic piece of verification. Assertion may contain some additional data (links, images, comments) set via 'data' parameter.

SoftAssertImage(message, img1, path, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report.
img1 object ImageWrapper object (1st image to compare).
path string Path to the second image to compare.
data SeSReportLink | SeSReportText | SeSReportImage | Object[] Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

SoftAssertLess

Checks if n1 is less than n2 and saves corresponding Report entry. Assertion is an atomic piece of verification. Assertion may contain some additional data (links, images, comments) set via 'data' parameter.

SoftAssertLess(message, n1, n2, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report.
n1 number First value to compare.
n2 number Second value to compare.
data SeSReportLink | SeSReportText | SeSReportImage | Object[] Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

SoftAssertLessOrEqual

Checks if n1 differs from n2 and saves corresponding Report entry. Assertion is an atomic piece of verification. Assertion may contain some additional data (links, images, comments) set via 'data' parameter.

SoftAssertLessOrEqual(message, n1, n2, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report.
n1 object First value to compare.
n2 object Second value to compare.
data SeSReportLink | SeSReportText | SeSReportImage | Object[] Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

SoftAssertNotContains

Checks that str does not contain substr anywhere and saves corresponding Report entry. Assertion is an atomic piece of verification. Assertion may contain some additional data (links, images, comments) set via 'data' parameter.

SoftAssertNotContains(message, str, substr, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report.
str string String to search in.
substr string Substring to find.
data SeSReportLink | SeSReportText | SeSReportImage | Object[] Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

SoftAssertNotEqual

Checks if obj1 differs from obj2 and saves corresponding Report entry. Assertion is an atomic piece of verification. Assertion may contain some additional data (links, images, comments) set via 'data' parameter.

SoftAssertNotEqual(message, obj1, obj2, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report.
obj1 object First object to compare.
obj2 object Second object to compare.
data SeSReportLink | SeSReportText | SeSReportImage | Object[] Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

SoftAssertNotNull

Checks if val is NotNull and saves corresponding Report entry. Assertion is an atomic piece of verification. Assertion may contain some additional data (links, images, comments) set via 'data' parameter.

SoftAssertNotNull(message, n1, n2, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report.
n1 number
n2 number
data SeSReportLink | SeSReportText | SeSReportImage | Object[] Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

SoftAssertNotSet

Checks if val is not set (i.e. it is null, 0, false or "") and saves corresponding Report entry. Assertion is an atomic piece of verification. Assertion may contain some additional data (links, images, comments) set via 'data' parameter.

SoftAssertNotSet(message, n1, n2, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report.
n1 number
n2 number
data SeSReportLink | SeSReportText | SeSReportImage | Object[] Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

SoftAssertNull

Checks if val is null and saves corresponding Report entry. Assertion is an atomic piece of verification. Assertion may contain some additional data (links, images, comments) set via 'data' parameter.

SoftAssertNull(message, n1, n2, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report.
n1 number
n2 number
data SeSReportLink | SeSReportText | SeSReportImage | Object[] Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

SoftAssertSet

Checks if val is set (i.e. not false, not 0, not null, not "") and saves corresponding Report entry. Assertion is an atomic piece of verification. Assertion may contain some additional data (links, images, comments) set via 'data' parameter.

SoftAssertSet(message, n1, n2, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report.
n1 number
n2 number
data SeSReportLink | SeSReportText | SeSReportImage | Object[] Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

SoftAssertStartsWith

Checks if str begins with substr and saves corresponding Report entry. Assertion is an atomic piece of verification. Assertion may contain some additional data (links, images, comments) set via 'data' parameter.

SoftAssertStartsWith(message, str, substr, data, tags) 

Parameters:

Name Type Description
message string Message to put in the report.
str string String to search in.
substr string Substring to find.
data SeSReportLink | SeSReportText | SeSReportImage | Object[] Additional information to put in the report. If 'string' is passed, then data is considered as additional comment attribute. Or 'array' may be passed. Each entry in the array should be one of: SeSReportLink, SeSReportImage, SeSReportText, SeSReportFile.
Optional.
tags object Hash of attributes to set for this particular log entry.
Optional.

SuppressReport

In SuppressReport mode all assertions are ignored. That means no lines are added to report and all statuses are treated as "Info". This mode is like IgnoreStatus mode but no status messages are added to report.

  Tester.SuppressReport(true);
  Tester.Assert("No assertion", false); // Status of this assertion will be ignored and no record will be added to report
  SeS('Obj1').DoClick(); // No line will be added to report and operation status will be ignored
  Tester.SuppressReport(false);
SuppressReport(suppress) 

Parameters:

Name Type Description
suppress boolean Set to 'True' to suppress adding anything into the report.