File tree Expand file tree Collapse file tree 2 files changed +12
-2
lines changed
example-karate/src/test/resources/features Expand file tree Collapse file tree 2 files changed +12
-2
lines changed Original file line number Diff line number Diff line change 1+ Feature : Demonstrate screenshot capturing
2+
3+ Background :
4+ * configure driver = { type: 'chrome' }
5+
6+ Scenario : I report scenario with a screenshot
7+ Given driver 'https://www.example.com'
8+ When def bytes = screenshot(false)
9+ Then karate.embed(bytes, 'image/png' )
Original file line number Diff line number Diff line change @@ -2,8 +2,9 @@ Feature: Demonstrate screenshot capturing on a test failure
22
33 Background :
44 * configure driver = { type: 'chrome' }
5+ * def expectedTitle = java.lang.System.getenv('RP_EXPECTED_TITLE' );
56
67 Scenario : I report scenario with a screenshot on failure
78 Given driver 'https://www.example.com'
8- When var expectedTitle = java.lang.System.getenv( 'RP_EXPECTED_TITLE' );
9- Then match driver.title == expectedTitle
9+ When def actualTitle = driver.title
10+ Then match actualTitle == expectedTitle
You can’t perform that action at this time.
0 commit comments