blob: 0dffc433342c604784da5b23a00069bcbbb0305f [file]
Tests node xPath construction
3 Prefix Suffix
4
5
6
'#document':'' - '/'
'#comment':' Pre-comment ' - '/comment()[1]'
'html':'' - '/html'
'head':'' - '/html/head'
'script':'' - '//*[@id="script-id"]'
'script':'' - '/html/head/script[2]'
'script':'' - '/html/head/script[4]'
'#text':'\n// Comment\n//' - '/html/head/script[4]/text()[1]'
'#cdata-section':'\nfunction f()\n{\n document.write("<");\n}\n//' - '/html/head/script[4]/text()[2]'
'body':'' - '/html/body'
'p':'' - '/html/body/p'
'#text':'Tests node xPath construction' - '/html/body/p/text()'
'div':'' - '//*[@id="id1"]'
'div':'' - '//*[@id="id2"]'
'div':'' - '//*[@id="container"]'
'div':'' - '//*[@id="id3"]'
'#text':'3 Prefix ' - '//*[@id="id3"]/text()[1]'
'#cdata-section':'<greeting>Hello, world!</greeting>' - '//*[@id="id3"]/text()[2]'
'#text':' Suffix' - '//*[@id="id3"]/text()[3]'
'div':'' - '//*[@id="id4"]'
'#text':'4' - '//*[@id="id4"]/text()'
'div':'' - '//*[@id="id5"]'
'#text':'5' - '//*[@id="id5"]/text()'
'div':'' - '//*[@id="id6"]'
'#text':'6' - '//*[@id="id6"]/text()'
'#comment':' Post-comment ' - '/comment()[2]'