Where communities thrive

  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
Repo info
    @Martis89 sounds like the same problem as mine! @NickTomlin let us know if you need any additional info from us!
    Nick Tomlin
    @Martis89 a few questions: 1. What OS are you using? 2. What version of jasmine are you using? 3. Are you using a custom reporter?
    @amistry03 you will need to print the output of your tests to STDOUT in addition to writing the XML file otherwise protractor-flake will not work. You may be able to just use multiple reporters (the standard one and the XML one)
    @NickTomlin 1 - I am using Ubuntu 14.03.3 LTS desktop. These tests are ran via Jenkins CI.
    2 - Jasmine version 2.0.
    3 - Karma-junit-reporter 0.2.2
    Nick Tomlin
    @Martis89 I believe you have the same problem as Amistry. You'll need to make sure you are also printing the test results to stdout
    Dmitry Sasov
    Hi @NickTomlin I just found out about protractor-flake and it looks really great, but I wasn't able to install it. Please see the error attached below. Am I right that it doesn't work with Protractor 3rd version and I have to downgrade to the protractor@2.x? Thank you!
    dima@lenovo-g50-70:~$ npm i -g protractor-flake
    npm WARN peerDependencies The peer dependency protractor@2.x included from protractor-flake will no
    npm WARN peerDependencies longer be automatically installed to fulfill the peerDependency 
    npm WARN peerDependencies in npm 3+. Your application will need to depend on it explicitly.
    /home/dima/.npm/bin/protractor-flake -> /home/dima/.npm/lib/node_modules/protractor-flake/bin/protractor-flake
    npm ERR! Linux 3.13.0-74-generic
    npm ERR! argv "/usr/local/bin/node" "/usr/local/bin/npm" "install" "-g" "protractor-flake"
    npm ERR! node v4.2.2
    npm ERR! npm  v2.14.7
    npm ERR! code EPEERINVALID
    npm ERR! peerinvalid The package protractor@3.0.0 does not satisfy its siblings' peerDependencies requirements!
    npm ERR! peerinvalid Peer protractor-flake@1.0.2 wants protractor@2.x
    npm ERR! Please include the following file with any support request:
    npm ERR!     /home/dima/npm-debug.log
    Chris Nguyen
    Hi @NickTomlin I'm running protractor-flake with multiCapabilities but it seems to be running all of tests on failure
    Sri Harsha
    Hi @Nick. Same happening to me , running all the tests on failure. [feat(protractor-flake)]: rerun only failed test on failure.
    Rohit Kadam
    @NickTomlin how to use protractor-flake with grunt, any sample example, documentation link will be useful?
    hi there, is the issue of running all of tests on failure solved? it is still happen to me unfortunately.
    Uma Mahesh
    How to handle this exception even if i am trying browser.wait and expected conditions still it raises exception
     Failed: unknown error: Element is not clickable at point (1269, 20). Other element would receive the click: <div modal-render="true" tabindex="-1" role="dialog" class="modal fade ng-isolate-scope full-screen-busy-spinner in" modal-animation-class="fade" ng-class="{in: animate}" ng-style="{'z-index': 1050 + index*10, display: 'block'}" ng-click="close($event)" modal-window="modal-window" window-class="full-screen-busy-spinner" index="0" animate="animate" modal-animation="true" style="z-index: 1050; display: block;">...</div>
    Uma Mahesh

    @NickTomlin I have followed your read me and added code to the protractor conf and trying to run using protractor-flake but i see the below text

    Using standard to parse output
    Re-running tests: test attempt 3

    Tests failed but no specs were found. All specs will be run again.

    **you must either specify a configuration file or at least 3 options. See below for the options:

    Usage: protractor [configFile] [options]
    configFile defaults to protractor.conf.js
    The [options] object will override values from the config file.
    See the reference config for a full list of options.```

    protractor-flake protractor-local.config.js I have customized config
    Jan-Niklas W.
    Hi everyone, is it possible to rerun protractor-flake just with failing tests due to timeouts? I think this would be a great possibility to improve the test quality.
    Luis Pablo
    Hello! :) Is somebody here?
    I have a little problem, I was using shardTestFiles: true in my protractor config because in one test I link an account with Facebook being on a dashboard interface, the next test unlinks account of facebook, and the next spec that is another file to test mobile interface I do this again, but if I'm not using shardTestFiles: true it obviously use the same browser so the process of linking a facebook account by second time is different and it doesn't display the log in pop up of facebook, that's why I was using shardTestsFiles, to avoid this issue and always pop up the facebook log in form, how can I solve my problem so I can use protractor-flake properly? Also, how I can make that it stops when the first failure happens and restart the test running?
    Hi, has anyone try to use this seemingly awesome plugin with gulp? The project I work already uses gulp-protractor to run protractor tests and I can't see an easy path to integrate it so wondering if someone can share me some example gulp task that uses protractor-flake (if you use gulp-protractor, that would be bonus but that is probably too much to ask) - Thanks for your help in advance!
    Khaja Moinuddin Mohammed
    Hello everyone. I was given protractor-flake a test but getting the following error.
    (function (exports, require, module, __filename, __dirname) { @IF EXIST "%~dp0\n
    ode.exe" (
    SyntaxError: Invalid or unexpected token
    I have tried various combinations of passing the protractor arguments but still facing the same issue
    node_modules\.bin\protractor-flake.cmd --protractor-path=node_modules\.bin\protractor.cmd --parser standard --node-bin node --max-attempts=3 --color=magenta -- suite=synthetic params.env syn_sat protractor.conf.js
    By the way the normal protractor tests run when i run from the command line as below
    node_modules\.bin\protractor.cmd protractor.conf.js --suite=synthetic --params.env syn_sat
    I have opened an issue against this here NickTomlin/protractor-flake#64
    Khaja Moinuddin Mohammed
    Not sure if it helps, but am using ES5 and not ES6 or Typescript for my protractor js tests
    Hello. Is it possible to use protractor-flake with Angular-CLI?
    Wilson Palkuri
    Hi @NickTomlin - I have same problem as @Martis89 and @amistry03. All my tests are being re run (both failed and passed). Where do you suggest to print test results ? i see that 'standard' parser is parsing the entire 'output'. Please advice or provide a written solution. Thanks.
    Wilson Palkuri
    @NickTomlin - Cn we use protractor-flake with --suite ? is there a fix for this yt ?

    @NickTomlin I added a flakey test output file for jasmine-spec-reporter, and the following unit test:

        it('isolates individual failed specs from jasmine-spec-reporter output', () => {
          protractorFlake({maxAttempts: 3})
          expect(spawnStub).to.have.been.calledWith('node', [pathToProtractor(), '--params.flake.retry', true, '--specs', '/tests/a-flakey.test.js'])

    but it's failing with this error:

      1) Protractor Flake failed specs isolates individual failed specs from jasmine-spec-reporter output:
         AssertionError: expected stub to have been called with arguments node, ["/Users/brine/protractor-flake/node_modules/protractor/bin/protractor", "--params.flake.retry", true, "--specs", "/tests/a-flakey.test.js"]%D
          at Context.<anonymous> (test/unit/index.test.js:103:38)

    What am I doon wrong?

    nvm :)
    Anyone know if I can use protractor-flake if I am using mocha as my framewrk? @NickTomlin
    Wim Selles

    Hi @faisalAvizia

    There is a PR for that one, see NickTomlin/protractor-flake#60. I asked @NickTomlin to merge it.

    So yep, there is a possibility, you just need to wait ;-)

    Thanks @wswebcreation . Hopefully it'll get merged soon. I am starting a new project and would love to use this.
    Trisha Chetani
    Trisha Chetani
    i need a suggestion on how to implement
    have added this file named as flake

    const protractorFlake = require('protractor-flake');
    // skip first two passed args (node and self)
    let protractorArgs = process.argv.splice(2);

    protractorPath: 'node_modules/.bin/protractor',
    maxAttempts: 2,
    parser: 'multi',
    nodeBin: 'node',
    protractorArgs: protractorArgs
    }, (status, output) => {

    but how does this file which read my config file , on success ful run it will know no need to re run the test
    and on failure it will re run the test
    any help
    Trisha Chetani
    custom parser module : how do i configure to re run the failed test only
    not all specs if returned empty

    module default {
    name: 'rerun',
    parse (protractorTestOutput) {
    let failedSpecs = new Set()
    // ... analyze protractor test output
    // ... and add to specFiles

        // specFiles to be re-run by protractor-flake
        // if an empty array is returned, all specs will be re-run
        return [...failedSpecs]


    Trisha Chetani
    what the difference between standard parser and multi parser
    Trisha Chetani
    how to stop running whole test and rerun only failed test
    Hi guys! I'm looking to use protractor-flake but it seems the sharded mode is not supported for the moment. Anybody wrote a parser for that by any chance? :p
    Oh I see there is the 'multi' parser now, great!
    I'll try it soon :)
    Wim Selles
    hi ;-)
    how are you tests configured?
    In the sense?