@@ -16,56 +16,44 @@ public function hasShippingEstimator(): bool
1616
1717 public function doesNotHaveAddressMessage (): bool
1818 {
19- $ message = $ this ->getElement ('enter_address_message ' );
20-
21- return $ message ->hasClass ('hidden ' );
19+ return $ this ->getElement ('enter_address_message ' )->hasClass ('hidden ' );
2220 }
2321
2422 public function hasAddressMessage (): bool
2523 {
26- $ message = $ this ->getElement ('enter_address_message ' );
27-
28- return !$ message ->hasClass ('hidden ' );
24+ return !$ this ->getElement ('enter_address_message ' )->hasClass ('hidden ' );
2925 }
3026
3127 public function doesNotHaveNoShippingOptionsMessage (): bool
3228 {
33- $ message = $ this ->getElement ('no_shipping_options_message ' );
34-
35- return $ message ->hasClass ('hidden ' );
29+ return $ this ->getElement ('no_shipping_options_message ' )->hasClass ('hidden ' );
3630 }
3731
3832 public function hasNoShippingOptionsMessage (): bool
3933 {
40- $ message = $ this ->getElement ('no_shipping_options_message ' );
41-
42- return !$ message ->hasClass ('hidden ' );
34+ return !$ this ->getElement ('no_shipping_options_message ' )->hasClass ('hidden ' );
4335 }
4436
4537 public function seeShippingOptions (int $ count ): bool
4638 {
47- $ table = $ this ->getElement ('shipping_options_table ' );
48- $ options = $ table ->findAll ('css ' , 'tbody tr ' );
39+ $ options = $ this ->getElement ('shipping_options_table ' )->findAll ('css ' , 'tbody tr ' );
4940
5041 return count ($ options ) === $ count ;
5142 }
5243
5344 public function selectCountry (string $ value ): void
5445 {
55- $ country = $ this ->getElement ('shipping_estimator_country ' );
56- $ country ->selectOption ($ value );
46+ $ this ->getElement ('shipping_estimator_country ' )->selectOption ($ value );
5747 }
5848
5949 public function specifyPostcode (string $ value ): void
6050 {
61- $ postcode = $ this ->getElement ('shipping_estimator_postcode ' );
62- $ postcode ->setValue ($ value );
51+ $ this ->getElement ('shipping_estimator_postcode ' )->setValue ($ value );
6352 }
6453
6554 public function clickEstimateShippingButton (): void
6655 {
67- $ button = $ this ->getElement ('estimate_shipping_button ' );
68- $ button ->click ();
56+ $ this ->getElement ('estimate_shipping_button ' )->click ();
6957
7058 JQueryHelper::waitForFormToStopLoading ($ this ->getDocument ());
7159 }
0 commit comments