{"library":"protractor-jasmine2-screenshot-reporter","title":"Protractor Jasmine2 Screenshot Reporter","description":"This package provides a dedicated reporter for Protractor, the end-to-end testing framework, specifically designed for use with Jasmine2. It automatically captures screenshots after each executed test case, whether passing or failing, and consolidates them into a single HTML report. Key features include configurable output directories, custom report filenames, the ability to include external CSS and JavaScript for custom styling and interactivity, and options to ignore pending specs or capture screenshots only for failed tests. The current stable version is 0.5.1. Given that its primary dependency, Protractor, was officially deprecated in 2022 and this reporter has not seen updates since 2016, it is effectively an abandoned project. There is no active release cadence, and it is not recommended for new projects.","language":"javascript","status":"abandoned","last_verified":"Sun Apr 19","install":{"commands":["npm install protractor-jasmine2-screenshot-reporter"],"cli":null},"imports":["var HtmlScreenshotReporter = require('protractor-jasmine2-screenshot-reporter');"],"auth":{"required":false,"env_vars":[]},"quickstart":{"code":"var HtmlScreenshotReporter = require('protractor-jasmine2-screenshot-reporter');\n\nvar reporter = new HtmlScreenshotReporter({\n  dest: 'target/screenshots',\n  filename: 'my-report.html'\n});\n\nexports.config = {\n  // ... Protractor configuration ...\n\n  // Setup the report before any tests start\n  beforeLaunch: function() {\n    return new Promise(function(resolve){\n      reporter.beforeLaunch(resolve);\n    });\n  },\n\n  // Assign the test reporter to each running instance\n  onPrepare: function() {\n    jasmine.getEnv().addReporter(reporter);\n  },\n\n  // Close the report after all tests finish\n  afterLaunch: function(exitCode) {\n    return new Promise(function(resolve){\n      reporter.afterLaunch(resolve.bind(this, exitCode));\n    });\n  }\n};","lang":"javascript","description":"This configuration snippet demonstrates how to integrate `protractor-jasmine2-screenshot-reporter` into a Protractor `conf.js` file, setting up the reporter lifecycle methods for `beforeLaunch`, `onPrepare`, and `afterLaunch` to capture screenshots and generate an HTML report.","tag":null,"tag_description":null,"last_tested":null,"results":[]},"compatibility":null}