@@ -2494,8 +2494,10 @@ def is_checked(self, selector, by="css selector", timeout=None):
2494
2494
kind = self.get_attribute(selector, "type", by=by, timeout=timeout)
2495
2495
if kind != "checkbox" and kind != "radio":
2496
2496
raise Exception("Expecting a checkbox or a radio button element!")
2497
- return self.get_attribute(
2498
- selector, "checked", by=by, timeout=timeout, hard_fail=False
2497
+ return bool(
2498
+ self.get_attribute(
2499
+ selector, "checked", by=by, timeout=timeout, hard_fail=False
2500
+ )
2499
2501
)
2500
2502
2501
2503
def is_selected(self, selector, by="css selector", timeout=None):
@@ -15166,9 +15168,12 @@ def setUp(self, masterqa_mode=False):
15166
15168
self.driver.close()
15167
15169
self.switch_to_window(0)
15168
15170
if self._crumbs:
15169
- self.wait_for_ready_state_complete()
15170
- with suppress(Exception):
15171
- self.driver.delete_all_cookies()
15171
+ if self.binary_location == "chs":
15172
+ self.delete_session_storage()
15173
+ else:
15174
+ self.wait_for_ready_state_complete()
15175
+ with suppress(Exception):
15176
+ self.driver.delete_all_cookies()
15172
15177
if self._reuse_session and sb_config.shared_driver and has_url:
15173
15178
good_start_page = False
15174
15179
if self.recorder_ext:
0 commit comments