From d5d808400794b54abafe2ffef958931037cf7625 Mon Sep 17 00:00:00 2001 From: omkarkhatavkar Date: Thu, 5 Nov 2020 13:46:42 +0530 Subject: [PATCH] adding separate ROOT to resolve #125 issue --- src/widgetastic_patternfly/__init__.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/widgetastic_patternfly/__init__.py b/src/widgetastic_patternfly/__init__.py index de83d77..474cebc 100644 --- a/src/widgetastic_patternfly/__init__.py +++ b/src/widgetastic_patternfly/__init__.py @@ -1974,7 +1974,8 @@ def active(self): @View.nested class date_pick(HeaderView): # noqa - DATES = ".//*[contains(@class, 'datepicker-days')]/table/tbody/tr/td" + ROOT = ".//*[contains(@class, 'datepicker-days')]" + DATES = ".//table/tbody/tr/td" @property def _elements(self): @@ -1986,7 +1987,8 @@ def _elements(self): @View.nested class month_pick(HeaderView): # noqa - MONTHS = ".//*[contains(@class, 'datepicker-months')]/table/tbody/tr/td/*" + ROOT = ".//*[contains(@class, 'datepicker-months')]" + MONTHS = ".//table/tbody/tr/td/*" @property def _elements(self): @@ -1998,7 +2000,8 @@ def _elements(self): @View.nested class year_pick(HeaderView): # noqa - YEARS = ".//*[contains(@class, 'datepicker-years')]/table/tbody/tr/td/*" + ROOT = ".//*[contains(@class, 'datepicker-years')]" + YEARS = ".//table/tbody/tr/td/*" @property def _elements(self):