FindSingle on adapter

Technology specific object identification, supported applications, web technologies, and 3rd party controls.
dkmpbrt
Posts: 31
Joined: Thu Jan 25, 2018 9:00 am
Location: Antwerp
Contact:

FindSingle on adapter

Post by dkmpbrt » Wed Feb 10, 2021 5:14 pm

Hey,

i'm trying to use FindSingle on an adapter. If I read the documentation, he would search for the xpath in that specific element. Although he applies the findsingle on the whole dom-element.

Item in repository:

Code: Select all

//div[@data-aut='fields.squad_name']

My code:

Code: Select all

[UserCodeMethod]
        public static void setDropdown(Adapter Dropdown, string waarde)
        {
        	InputTag myInput = (InputTag)Dropdown.FindSingle("//input");
      
        	Report.Info(myInput.GetPath().ToString());

        }
The report info returns

Code: Select all

/dom//input[#'attachmentInput'] 
although I expect something like this:

Code: Select all

/dom//div[@data-aut='fields.squad_name']//input[#'attachmentInput']
Kr,
Bart

dkmpbrt
Posts: 31
Joined: Thu Jan 25, 2018 9:00 am
Location: Antwerp
Contact:

Re: FindSingle on adapter

Post by dkmpbrt » Fri Mar 19, 2021 9:51 am

^bump