Compare Date
Last updated
Last updated
This is a pre-built action in Avo Assure which is Located under the @Generic element category. It instructs the Avo Assure Client to compare the given dates with the same format and save the results in the output variable.
Input: <date 1> ;< date 2> ;< date1 format>
Supported date formats:
1. dd/MM/yyyy
2. MM/dd/yyyy
3. dd/MMM/yyyy
4. MMM/dd/yyyy
Output: <Dynamic Variable> ;< Dynamic Variable> (Optional)
Consider a scenario where you are testing an e-commerce application where a promotional discount is available for a limited time. The application needs to verify if the current date falls within the promotion's start and end dates to determine if the discount should be applied at checkout. It Validate that the user interface displays accurate messages regarding the promotion's availability. It Confirm that the application does not apply the discount if the Current Date is outside the specified date range.
Input Data:
Promotion Start Date: 10/09/2023
Promotion End Date: 10/09/2024
Current Date: 24/10/2024
Expected output:
The system should determine if the current date 24/10/2024 is within the promotion period or not. If the date is outside the range (from 10/09/2023 to 10/09/2024) then a promotion discount is not applicable.
The promotional discount should not be applied at checkout since the current date is outside the range of the applicable date.
Output: The action performed and saves the result in {result} output variable as false.
Description and Usage: This is a pre-built action in Avo Assure which is Located under the @Generic element category. It instructs the Avo Assure Client to compare the given dates with the same format and save the results in the output variable.
Syntax:
Input: <date 1> ;< date 2> ;< date1 format>
Supported date formats:
1. dd/MM/yyyy
2. MM/dd/yyyy
3. dd/MMM/yyyy
4. MMM/dd/yyyy
Output: <Dynamic Variable> ;< Dynamic Variable> (Optional)
Use case/Example:
Scenario: Promotional Offer Validation Consider a scenario where a user is testing an e-commerce application where a promotional discount is available for a limited time. The application needs to verify if the current date falls within the promotion's start and end dates to determine if the discount should be applied at checkout. It Validate that the user interface displays accurate messages regarding the promotion's availability. It Confirm that the application does not apply the discount if the Current Date is outside the specified date range.
Input Data:
Promotion Start Date: 10/09/2023
Promotion End Date: 10/09/2024
Current Date: 24/10/2024
Expected output:
The system should determine if the current date 24/10/2024 is within the promotion period or not. If the date is outside the range (from 10/09/2023 to 10/09/2024) then a promotion discount is not applicable.
The promotional discount should not be applied at checkout since the current date is outside the range of the applicable date
Output: The action performed and saves the result in {result} output variable as false.