Capturing JavaScript error in Selenium

前端 未结 12 738
盖世英雄少女心
盖世英雄少女心 2020-12-02 08:15

Is there a way to capture errors occurring in the DOM in Selenium and probably flag the same as an error in the page?

To give a brief exam

12条回答
  •  没有蜡笔的小新
    2020-12-02 08:33

    Put this script on your page and then check in Selenium for the JSError:

    
    

提交回复
热议问题