Overview
The Revyl YAML format allows you to define end-to-end tests in a structured, human-readable format. Tests support conditional logic, loops, variable extraction, and various action types for iOS and Android platforms.
Test Execution Behavior
Important: When a test starts, Revyl automatically opens the application and installs it if needed.
You do NOT need to include manual open_app steps at the beginning of your test. These manual steps are only needed when reopening the app after closing it.
Most tests should start directly with instructions or validations.
Root Structure
The test Object
All YAML tests start with a test: root object containing three main sections:
test:
metadata: # Test configuration
build: # Build reference
blocks: # Test steps
The metadata section contains test-level configuration:
name
Required | string
The name of your test.
metadata:
name: "User Login Flow"
Optional | string | Values: ios, android
Target platform for the test. If omitted, platform is inferred from the build.
metadata:
name: "Mobile Checkout"
platform: ios
Build Section
The build section specifies which application version to test:
name
Required | string
Name of the build to test against.
build:
name: "Production App"
pinned_version
Optional | string
Specific version to test. If omitted, uses latest build.
build:
name: "Staging App"
pinned_version: "2.5.1"
Blocks Section
blocks
Required | array
List of test steps executed sequentially.
Tests automatically open the app at start, so blocks typically begin with instructions or validations.
Block Types
Instructions Block
AI-powered actions that execute natural language instructions. Use high-level instructions for complex flows.
Fields:
type: “instructions” (required)
step_description: Natural language instruction (required)
Example:
# High-level instruction (recommended for complex flows)
- type: instructions
step_description: "Complete the sign up flow"
# Specific instruction
- type: instructions
step_description: "Tap the login button"
Validation Block
Assert conditions to verify application state.
Fields:
type: “validation” (required)
step_description: Condition to validate (required)
Example:
- type: validation
step_description: "The dashboard page is visible"
Extract data from the application and store in variables.
Fields:
type: “extraction” (required)
step_description: What to extract (required)
variable_name: Variable name to store the extracted value (required, use kebab-case)
Example:
- type: extraction
step_description: "The product price"
variable_name: product-price
Manual Block
Direct operations that bypass AI processing.
Fields:
type: “manual” (required)
step_type: Type of manual operation (required)
step_description: The value/parameter for the operation (format depends on step_type)
Manual step_type values:
| step_type | Description | step_description format |
|---|
wait | Pause for specified seconds | Duration in seconds (e.g., "2") |
open_app | Launch installed app or system app | Bundle ID for system apps, or empty for installed app |
kill_app | Completely terminates the app | Optional (not used) |
go_home | Navigate to home screen | Optional (not used) |
navigate | Open a deep link URL | The URL to open (e.g., "myapp://settings") |
set_location | Set device GPS location | Latitude,Longitude (e.g., "37.7749,-122.4194") |
kill_app vs go_home:
kill_app: Fully terminates the app process. The app is completely closed and will cold-start when reopened. Use this to test app restart behavior, state persistence after termination, or to clear app memory.
go_home: Navigates to the device home screen but keeps the app running in the background. The app remains in memory and will resume from where it left off. Use this to test background/foreground transitions or multitasking scenarios.
System App Bundle IDs (for open_app):
| App | iOS Bundle ID | Android Bundle ID |
|---|
| Settings | com.apple.Preferences | com.android.settings |
| Safari/Chrome | com.apple.mobilesafari | com.android.chrome |
| Photos | com.apple.mobileslideshow | com.google.android.apps.photos |
| Contacts | com.apple.MobileAddressBook | com.google.android.contacts |
| Maps | com.apple.Maps | com.google.android.apps.maps |
| Messages | com.apple.MobileSMS | com.google.android.apps.messaging |
| Calendar | com.apple.mobilecal | com.google.android.calendar |
| Files | com.apple.DocumentsApp | com.google.android.documentsui |
Code Execution steps are not supported in YAML. Script/code execution steps created in the visual editor cannot be exported to YAML.
Examples:
# Wait 2 seconds
- type: manual
step_type: wait
step_description: "2"
# Open a deep link
- type: manual
step_type: navigate
step_description: "myapp://settings/profile"
# Open installed app (default - empty or omit step_description)
- type: manual
step_type: open_app
# Open Photos system app (iOS)
- type: manual
step_type: open_app
step_description: "com.apple.mobileslideshow"
# Open Settings system app (Android)
- type: manual
step_type: open_app
step_description: "com.android.settings"
# Go to home screen
- type: manual
step_type: go_home
# Kill the app
- type: manual
step_type: kill_app
# Set GPS location to San Francisco (lat,long format)
- type: manual
step_type: set_location
step_description: "37.7749,-122.4194"
If Block
Conditional branching with then/else paths.
Fields:
type: “if” (required)
condition: Natural language condition (required)
then: Array of blocks executed when condition is true (required)
else: Array of blocks executed when condition is false (optional)
Example:
- type: if
condition: "A discount code field is visible"
then:
- type: instructions
step_description: "Enter 'SAVE10' in the discount code"
- type: instructions
step_description: "Click 'Apply'"
else:
- type: validation
step_description: "No discount option is available"
While Block
Loop with a condition that repeats the body until condition is false.
Fields:
type: “while” (required)
condition: Loop continuation condition (required)
body: Array of blocks executed each iteration (required)
Example:
- type: while
condition: "More items button is visible"
body:
- type: instructions
step_description: "Click 'Load More'"
- type: manual
step_type: wait
step_description: "1"
Using Variables
Variables allow you to extract and reuse data throughout your test.
Defining Variables:
- type: extraction
step_description: "The product price"
variable_name: product-price
Using Variables:
Wrap variable names with double curly braces:
- type: validation
step_description: "Total is {{product-price}}"
- type: instructions
step_description: "Enter '{{username}}' in the username field"
Variables can be used in any step_description or condition field.
Complete Example
test:
metadata:
name: "E-commerce Checkout Flow"
platform: ios
build:
name: "Shopping App"
pinned_version: "2.1.0"
blocks:
# Test starts automatically with app open
# No manual open_app needed
- type: instructions
step_description: "Search for 'laptop'"
- type: instructions
step_description: "Tap the first search result"
- type: extraction
step_description: "The product price"
variable_name: product-price
- type: instructions
step_description: "Tap 'Add to Cart'"
- type: validation
step_description: "The cart shows price of {{product-price}}"
- type: if
condition: "A discount code field is visible"
then:
- type: instructions
step_description: "Enter 'SAVE10' in the discount code"
- type: instructions
step_description: "Tap 'Checkout'"
- type: validation
step_description: "The order confirmation page is displayed"