@@ -13,73 +13,73 @@ def when_i_submit_my_participant_id(context):
1313@when ('I fill in and submit my smoking status with "{smoking_status}"' )
1414def when_i_fill_in_and_submit_my_smoking_status (context , smoking_status ):
1515 context .page .get_by_label (smoking_status ).check ()
16- context . page . click ( "text=Continue" )
16+ when_i_submit_the_form ( context )
1717
1818@when ('I fill in and submit my date of birth with "{date_of_birth}"' )
1919def when_i_fill_in_and_submit_my_date_of_birth (context , date_of_birth ):
2020 day , month , year = date_of_birth .split ('-' )
2121 context .page .get_by_label ('Day' ).fill (day )
2222 context .page .get_by_label ('Month' ).fill (month )
2323 context .page .get_by_label ('Year' ).fill (year )
24- context . page . click ( "text=Continue" )
24+ when_i_submit_the_form ( context )
2525
2626@when (u'I fill in and submit my date of birth as {years} years ago' )
2727def when_i_fill_in_and_submit_my_date_of_birth_as_x_years_ago (context , years ):
2828 date_of_birth = datetime .now () - relativedelta (years = int (years ))
2929 context .page .get_by_label ('Day' ).fill (str (date_of_birth .day ))
3030 context .page .get_by_label ('Month' ).fill (str (date_of_birth .month ))
3131 context .page .get_by_label ('Year' ).fill (str (date_of_birth .year ))
32- context . page . click ( "text=Continue" )
32+ when_i_submit_the_form ( context )
3333
3434@when (u'I fill in and submit my height with "{height}"' )
3535def when_i_fill_in_and_submit_my_height (context , height ):
3636 context .page .get_by_label ('Centimetre' ).fill (height )
37- context . page . click ( "text=Continue" )
37+ when_i_submit_the_form ( context )
3838
3939@when (u'I fill in and submit my height with "{feet}" feet and "{inches}" inch' )
4040@when (u'I fill in and submit my height with "{feet}" feet and "{inches}" inches' )
4141def when_i_fill_in_and_submit_my_height_with_feet_and_inches (context , feet , inches ):
4242 context .page .get_by_label ('Feet' ).fill (feet )
4343 context .page .get_by_label ('Inches' ).fill (inches )
44- context . page . click ( "text=Continue" )
44+ when_i_submit_the_form ( context )
4545
4646@when (u'I fill in and submit my weight with "{weight}"' )
4747def when_i_fill_in_and_submit_my_weight (context , weight ):
4848 context .page .get_by_label ('Kilograms' ).fill (weight )
49- context . page . click ( "text=Continue" )
49+ when_i_submit_the_form ( context )
5050
5151@when (u'I fill in and submit my weight with "{stone}" stone and "{pounds}" pound' )
5252@when (u'I fill in and submit my weight with "{stone}" stone and "{pounds}" pounds' )
5353def stone_and_pounds (context , stone , pounds ):
5454 context .page .get_by_label ('Stone' ).fill (stone )
5555 context .page .get_by_label ('Pounds' ).fill (pounds )
56- context . page . click ( "text=Continue" )
56+ when_i_submit_the_form ( context )
5757
5858@when (u'I fill in and submit my sex at birth with "{sex_at_birth}"' )
5959def when_i_fill_in_and_submit_my_sex_at_birth (context , sex_at_birth ):
6060 context .page .get_by_label (sex_at_birth , exact = True ).check ()
61- context . page . click ( "text=Continue" )
61+ when_i_submit_the_form ( context )
6262
6363@when (u'I fill in and submit my gender with "{gender}"' )
6464def when_i_fill_in_and_submit_my_gender (context , gender ):
6565 context .page .get_by_label (gender , exact = True ).check ()
66- context . page . click ( "text=Continue" )
66+ when_i_submit_the_form ( context )
6767
6868@when (u'I fill in and submit my ethnicity with "{ethnicity}"' )
6969def when_i_fill_in_and_submit_my_ethnicity (context , ethnicity ):
7070 context .page .get_by_label (ethnicity , exact = True ).check ()
71- context . page . click ( "text=Continue" )
71+ when_i_submit_the_form ( context )
7272
7373@when (u'I fill in and submit my respiratory conditions with "{condition_a}" and "{condition_b}"' )
7474def when_i_fill_in_and_submit_my_respiratory_conditions (context , condition_a , condition_b ):
7575 context .page .get_by_label (condition_a ).check ()
7676 context .page .get_by_label (condition_b ).check ()
77- context . page . click ( "text=Continue" )
77+ when_i_submit_the_form ( context )
7878
7979@when (u'I fill in and submit my asbestos exposure with "{asbestos_exposure}"' )
8080def when_i_fill_in_and_submit_my_asbestos_exposure (context , asbestos_exposure ):
8181 context .page .get_by_label (asbestos_exposure , exact = True ).check ()
82- context . page . click ( "text=Continue" )
82+ when_i_submit_the_form ( context )
8383
8484@when ('I submit the form' )
8585def when_i_submit_the_form (context ):
0 commit comments