GithubHelp home page GithubHelp logo

igniteram / protractor-cucumber-allure Goto Github PK

View Code? Open in Web Editor NEW
49.0 20.0 47.0 2.09 MB

e2e kickstarter framework for using protractorJS with cucumberJS and allure jenkins CI reports

License: MIT License

JavaScript 89.39% Gherkin 10.61%
protractor cucumberjs allure-report

protractor-cucumber-allure's Issues

Parallel execution does not work

When tried to run tests in parallel via multiConfig.js, 4 instances are launched with console message "I/launcher - Running 4 instances of WebDriver" and protractor execution hangs indefinitely.

Node: v8.11.2
npm: 5.6.0

Upgrading cuucmber-protratctor-framework and cuucmber version to latest version breaks the tests

I upgraded to below

"cucumber": "^2.0.0",
"protractor": "^5.0.0",
"protractor-cucumber-framework": "^2.0.0"

and tests now break with error below

Unhandled rejection Error: Not empty
at TagExpressionParser.parse (C:\code\protractor-cucumber-allure-master\node
_modules\cucumber-tag-expressions\lib\tag_expression_parser.js:49:13)
at new ScenarioFilter (C:\code\protractor-cucumber-allure-master\node_module
s\cucumber\lib\scenario_filter.js:44:52)
at Cli. (C:\code\protractor-cucumber-allure-master\node_modules\c
ucumber\lib\cli\index.js:145:30)
at next (native)
at undefined.tryCatcher (C:\code\protractor-cucumber-allure-master\node_modu
les\bluebird\js\release\util.js:16:23)
at PromiseSpawn._promiseFulfilled (C:\code\protractor-cucumber-allure-master
\node_modules\bluebird\js\release\generators.js:97:49)
at Promise._settlePromise (C:\code\protractor-cucumber-allure-master\node_mo
dules\bluebird\js\release\promise.js:574:26)
at Promise._settlePromise0 (C:\code\protractor-cucumber-allure-master\node_m
odules\bluebird\js\release\promise.js:614:10)
at Promise._settlePromises (C:\code\protractor-cucumber-allure-master\node_m
odules\bluebird\js\release\promise.js:693:18)
at Async._drainQueue (C:\code\protractor-cucumber-allure-master\node_modules
\bluebird\js\release\async.js:133:16)
at Async._drainQueues (C:\code\protractor-cucumber-allure-master\node_module
s\bluebird\js\release\async.js:143:10)
at Immediate.Async.drainQueues (C:\code\protractor-cucumber-allure-master\no
de_modules\bluebird\js\release\async.js:17:14)
at runCallback (timers.js:672:20)
at tryOnImmediate (timers.js:645:5)
at processImmediate [as _immediateCallback] (timers.js:617:5)

function timed out after 5000 milliseconds

protractor-cucumber-allure.zip
Hi,
I am able to create POM using your framework, but the problem is when i run " NPM Test". It is just opening the web browser and directly giving the results with out interacting with the web elements.So i have added CallBack in my each step def function. Then i am getting "function timed out after 5000 milliseconds" error message.

If i remove callBack it is running with out errors but giving results directly without interacting with application.
If i add callBack it is throwing ""function timed out after 5000 milliseconds".

Please could you help me with the solution.
``

CucumberHtmlReport is not a constructor

While executing , I am getting following error :
[17:14:37] E/launcher - CucumberHtmlReport is not a constructor
[17:14:37] E/launcher - TypeError: CucumberHtmlReport is not a constructor

Chrome Driver Execution: Error message: Could not find update-config.json. Run 'webdriver-manager update' to download binaries.

Hi Ram,

Script is not getting executed on changing the browser in config.js from "firefox" to "chrome".
The issue here was that you need to specify the path to your selenium jar and chrome driver exe in your protractor config file. Mine was installed globally in AppData folder so i have mentioned the path of both the variables i.e chrome driver and selenium standalone server in config.js and things started working for me as expected.
OR
Copy the selenium folder from the AppData folder and place it within the solution explorer under "protractor-cucumber-allure-master\node_modules\protractor\node_modules\webdriver-manager".

Json reports name issue

Hi Ram,
The json report get generated based on the option json:./reports/json/cucumber_report.json in Cucumber opts section result in json file gernated like cucumber_report1234.json(some additional number in the file name),so HTML report genrateion get failed as the Traget json name mismatch.

Not able to run test by command 'npm test'

when trying to run test after doing npm install, i am getting following error:
[23:42:12] I/launcher - Running 1 instances of WebDriver
[23:42:12] I/direct - Using ChromeDriver directly...
[23:42:12] E/direct - Error code: 135
[23:42:12] E/direct - Error message: Could not find update-config.json. Run 'webdriver-manager update' to download binaries.
[23:42:12] E/direct - Error: Could not find update-config.json. Run 'webdriver-manager update' to download binaries.
at IError (/Users/vijaysingh/Desktop/cucumber/protractor-cucumber-allure-master/node_modules/protractor/built/exitCodes.js:5:1)
at ProtractorError (/Users/vijaysingh/Desktop/cucumber/protractor-cucumber-allure-master/node_modules/protractor/built/exitCodes.js:10:9)
at BrowserError (/Users/vijaysingh/Desktop/cucumber/protractor-cucumber-allure-master/node_modules/protractor/built/exitCodes.js:51:9)
at Direct.getNewDriver (/Users/vijaysingh/Desktop/cucumber/protractor-cucumber-allure-master/node_modules/protractor/built/driverProviders/direct.js:62:31)
at Runner.createBrowser (/Users/vijaysingh/Desktop/cucumber/protractor-cucumber-allure-master/node_modules/protractor/built/runner.js:194:43)
at q.then.then (/Users/vijaysingh/Desktop/cucumber/protractor-cucumber-allure-master/node_modules/protractor/built/runner.js:338:29)
at _fulfilled (/Users/vijaysingh/Desktop/cucumber/protractor-cucumber-allure-master/node_modules/q/q.js:834:54)
at self.promiseDispatch.done (/Users/vijaysingh/Desktop/cucumber/protractor-cucumber-allure-master/node_modules/q/q.js:863:30)
at Promise.promise.promiseDispatch (/Users/vijaysingh/Desktop/cucumber/protractor-cucumber-allure-master/node_modules/q/q.js:796:13)
at /Users/vijaysingh/Desktop/cucumber/protractor-cucumber-allure-master/node_modules/q/q.js:556:49
[23:42:12] E/launcher - Process exited with error code 135

I have tried running webdriver-manager update, but no luck.
Please suggest a way to fix as soon as possible.

Thank you
Vijay

browser.restart with Page object pattern do not work

Hi again!

I am facing a problem when trying to implement a restart between scenarios.

Changes I done :

registerHandler("BeforeScenario", { timeout: 10 * 1000 }, function() {
return browser.get(conf.baseUrl);
});

After(function(scenario) {
if (scenario.isFailed()) {
var attach = this.attach; // cucumber's world object has attach function which should be used
return browser.takeScreenshot().then(function(png) {
var decodedImage = new Buffer(png, "base64");
attach(decodedImage, "image/png");
return browser.restart();
})
}
});

And this restarts the browser between tests, but strangely I am getting exception same as mentioned in this ticket :

angular/protractor#3595

Can you please help here to understand what's happening. And how I can utilie the world object as explained in above solution (if really thats the only option )

I really want to close the browser in case of failure of the tests.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.