"find element `a` that contains string ""text a"" in file `root`","e = root.xpath('.//a[contains(text(),""TEXT A"")]')"