Screenshots using Selenium IDE Firefox plugin -
using selenium ide firefox plugin, want take automated screenshots. test script contains of 2 lines:
command: open; target: http://www.google.com command: captureentirepagescreenshotandwait
the log shows:
[info] executing: |open | http://www.google.com | | [info] executing: |captureentirepagescreenshotandwait | | | [error] unexpected exception: [exception... "component returned failure code: 0x80520001 (ns_error_file_unrecognized_path) [nsilocalfile.initwithpath]" nsresult: "0x80520001 (ns_error_file_unrecognized_path)" location: "js frame :: chrome://selenium-ide/content/selenium-core/scripts/selenium-api.js :: <top_level> :: line 3045" data: no]. tostring -> function tostring() { [native code] }, message -> component returned failure code: 0x80520001 (ns_error_file_unrecognized_path) [nsilocalfile.initwithpath], result -> 2152857601, name -> ns_error_file_unrecognized_path, filename -> chrome://selenium-ide/content/selenium-core/scripts/selenium-api.js, linenumber -> 3045, columnnumber -> 0, inner -> null, data -> null, location -> js frame :: chrome://selenium-ide/content/selenium-core/scripts/selenium-api.js :: <top_level> :: line 3045
how screenshots?
setting file path correctly solved it. path needs set follows:
(windows:)
command: captureentirepagescreenshotandwait; target: d:\\screenshots\\test.png
(linux:)
command: captureentirepagescreenshotandwait; target: \\screenshots\\test.png
in example, folder 'screenshots' must exist.
Comments
Post a Comment