-
公开(公告)号:US11416381B2
公开(公告)日:2022-08-16
申请号:US16931821
申请日:2020-07-17
Applicant: MICRO FOCUS LLC
Inventor: Er-Xin Shang , Bin Zhou , Chao-Lin Jiang , Ran Li
IPC: G06F40/197 , G06F17/00 , G06F11/36 , G06F16/901 , G06F16/958 , G06F16/9535 , G06F40/123 , G06F11/34 , G06F40/143 , G06F40/117 , G06F16/951
Abstract: This document describes techniques and apparatuses for supporting web components associated with a document object model (DOM) corresponding to a data file in a web testing environment. A user interaction, relative to a web page or web application from which the DOM is rendered, is monitored in the web testing environment. The monitoring identifies a target element selected by the user that is referenced in a shadow DOM associated with the DOM. One or more parent shadow host elements of the DOM are identified relative to the target element. The one or more shadow host elements define a reduced path, with respect to a tree data structure representing the DOM and the shadow DOM, for linking a document object of the DOM to the target element. Indicia identifying the one or more shadow host elements as linking the document object of the DOM to the target element are recorded. The recorded indicia define the reduced path for identifying the target element relative to the document object in the tree data structure during a replay of a recorded session of the user interaction. A target element may also be identified and replaced with a different object by referencing the one or more shadow host elements.