'Verifies checkbox identified by `locator` is selected/checked.
Key attributes for checkboxes are `id` and `name`. See `introduction`
for details about locating elements.'

@keyword
def checkbox_should_be_selected(self, locator):

    self.info(("Verifying    checkbox    '%s'    is    selected." % locator))
    element = self._get_checkbox(locator)
    if (not element.is_selected()):
        raise AssertionError(("Checkbox    '%s'    should    have    been    selected    but    was    not" % locator))
