Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 16 additions & 13 deletions website/static/code-examples/browser/insurance.robot
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
*** Settings ***
Library Browser
Library DateTime

*** Variables ***
${BROWSER} chromium
Expand Down Expand Up @@ -31,7 +32,7 @@ Enter Vehicle Data for Automobile
Fill Text id=listprice 30000
Fill Text id=licenseplatenumber DMK1234
Fill Text id=annualmileage 10000
Click section[style="display: block;"] >> text=Next »
Click id=nextenterinsurantdata

Enter Insurant Data
[Arguments] ${firstname}=Max ${lastname}=Mustermann
Expand All @@ -45,31 +46,33 @@ Enter Insurant Data
Fill Text id=city Essen
Select Options By id=occupation text Employee
Click text=Cliff Diving
Click section[style="display: block;"] >> text=Next »
Click id=nextenterproductdata

Enter Product Data
Fill Text id=startdate 06/01/2023
${today}= Get Current Date
${now_in_60d}= Add Time To Date ${today} 60 days result_format=%m/%d/%Y
Fill Text id=startdate ${now_in_60d}
Select Options By id=insurancesum text 7.000.000,00
Select Options By id=meritrating text Bonus 1
Select Options By id=damageinsurance text No Coverage
Check Checkbox *css=label >> id=EuroProtection
Select Options By id=courtesycar text Yes
Click section[style="display: block;"] >> text=Next »
Click id=nextselectpriceoption

Select Price Option
[Arguments] ${price_option}=Silver
Click *css=label >> css=[value=${price_option}]
Click section[style="display: block;"] >> text=Next »
Click id=nextsendquote

Send Quote
Fill Text "E-Mail" >> .. >> input max.mustermann@example.com
Fill Text "Phone" >> .. >> input 0049201123456
Fill Text "Username" >> .. >> input max.mustermann
Fill Text "Password" >> .. >> input SecretPassword123!
Fill Text "Confirm Password" >> .. >> input SecretPassword123!
Fill Text "Comments" >> .. >> textarea Some comments
${promise}= Promise To Wait For Response matcher=http://sampleapp.tricentis.com/101/tcpdf/pdfs/quote.php timeout=10
Click "« Send »"
Fill Text id=email max.mustermann@example.com
Fill Text id=phone 0049201123456
Fill Text id=username max.mustermann
Fill Text id=password SecretPassword123!
Fill Text id=confirmpassword SecretPassword123!
Fill Text id=Comments Some comments
${promise}= Promise To Wait For Response matcher=https://sampleapp.tricentis.com/101/tcpdf/pdfs/quote.php timeout=15
Click id=sendemail
${body}= Wait For ${promise}
Log ${body}[status]
Log ${body}[body]
Expand Down