Run and debug JavaScript
Execute JavaScript in Flows using inline expressions, evalScript, or runScript with console.log debugging.
Execution Methods
1. In-line expressions
- launchApp
- inputText: ${'User_' + faker.name().firstName()} # Generates a dynamic username
- tapOn: ${maestro.platform === 'ios' ? 'Allow' : 'While using the app'} # Conditional logic2. The evalScript Command
- evalScript: ${output.timestamp = new Date().getTime()} # Store data for later use
- evalScript: ${console.log('Test execution started')} # Inline logging3. The runScript Command
Logging and debugging
Logging with evalScript command
Logging in external files
Next steps
Last updated