def _is_text_visible(self, element, text, strict=True):
    try:
        if strict:
            return (element.text == text)
        else:
            return (text in element.text)
    except Exception:
        return False
def _is_text_visible(self, element, text, strict=True):
    try:
        if strict:
            return (element.text == text)
        else:
            return (text in element.text)
    except Exception:
        return False