Skip to content

Instantly share code, notes, and snippets.

@lokimeyburg
Created April 29, 2014 17:29
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lokimeyburg/11406834 to your computer and use it in GitHub Desktop.
Save lokimeyburg/11406834 to your computer and use it in GitHub Desktop.
Take a picture with Protractor
browser.takeScreenshot().then(function (png) {
var fs = require('fs'),
buf = new Buffer(png, 'base64'),
stream = fs.createWriteStream('exception.png');
stream.write(buf);
stream.end();
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment