0% found this document useful (0 votes)
2 views

Advanced Built-In Functions Printable Resource

The document outlines various built-in functions available at the University of Provar, categorized into date, number, string manipulation, test case, and other functions. It provides examples and usage tips for functions such as DateFormat, NumberFormat, StringNormalize, and TestCaseOutcome. Additionally, it includes guidance on accessing these functions through Content Assist in the Test Builder.

Uploaded by

sikander
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
2 views

Advanced Built-In Functions Printable Resource

The document outlines various built-in functions available at the University of Provar, categorized into date, number, string manipulation, test case, and other functions. It provides examples and usage tips for functions such as DateFormat, NumberFormat, StringNormalize, and TestCaseOutcome. Additionally, it includes guidance on accessing these functions through Content Assist in the Test Builder.

Uploaded by

sikander
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

University of Provar

Provar Advanced Built-In Functions

Accessing Built-In Functions


For a list of built-in functions, use Content Assist (Ctrl + Space) on
● Set Values API
● While recording the test in the Test Builder under Set Interaction

Pro tip: Select and click on the function and the details will be displayed.

Date Functions
DateFormat
Useful when you need to use date fields that require specific formatting.
Example: {DateFormat("2022-11-12", "MM-dd-YY")} to show a date of 11-12-22
Note: You can also used TODAY and DateADD with it.

DateParse
Useful for when you need to convert a string to a date.

Number Functions
NumberFormat
Allows you to format a number in a defined patterns

Round
Rounds a number to a defined specification.
You can choose UP, DOWN, or FLOOR.

String Manipulation Functions


StringNormalize
Normalizes a supplied String in various possible ways such as removing any leading or
trailing whitespace or removing consecutive whitespace characters.

StringReplace
Allows you to modify and parameterize a body of text.

StringTrim
Trims whitespace from a string. You can choose trim leading or trailing whitespaces
from a string.
University of Provar

TestCase Functions
TestCaseName
Returns the current test case name.

TestCaseOutcome
Returns the outcome of the test case. The outcome depends on the steps executed
before the function calling step. This returns Successful if the test case is passing and
Failed if the test case if failing.

TestCasePath
Returns the path of the test case.

TestCaseSuccessful
Returns if the test case is successful. It will return the boolean value True if the test case
is passing, False if the test case is failing.

TestRunErrors
Returns all of the errors that occurred during the test run. This is useful during batch
execution. You can use this function at the beginning or at the end of a test case. As a
recommended practice, we suggest you leverage this function at the end of a test case.

TestCaseErrors
Returns the list which contains all of the errors that came before running this function.

Other Functions
Count
Allows you to count the number of items in a list. For example, it can be useful to check
the number of values returned from a SOQL or SQL query.

Not
Negates a condition and will return a boolean value.

IsSorted
Tests whether a supplied list of values is sorted in Ascending or Descending order.

GetEnvironmentVariable
Returns the System and UserDefined environment variable.

GetSelectedVariable
Returns a selected environment. This is useful if you want to run the same test case in
different environments.

You might also like