variables: site_url: '{{ browser }}' code: 'VWJ367' steps: - selenium: test: driver: '/usr/lib/chromedriver' file: resources/create-flight.js register: {title: '{{ OUTPUT.title }}'} - echo: {from: '{{ title }}', to: variable.output} - postgres: request: conf: '{{ postgres_flights }}' sql: "select count(*) from flights where flight_code = '{{ code }}'" register: {count: '{{ OUTPUT.count }}'} - check: equals: {the: 1, is: '{{ count }}'} finally: - postgres: request: conf: '{{ postgres_flights }}' sql: "delete from flights where flight_code = '{{ code }}'"