Protractor, Jasmine, and stopping test on first fail

后端 未结 1 2009
傲寒
傲寒 2021-02-09 03:42

While trying to figure out how to make certain jasmine expect statements dependent on a previous expect statement I discovered that previous to Jasmine 2.3.0, there was not a wa

1条回答
  •  囚心锁ツ
    2021-02-09 04:19

    From what I see in the protractor and jasmine-npm (the jasmine runner that protractor uses) source code, it is not as simple as adding the stopSpecOnExpectationFailure or stopOnFailure jasmine node option to the configuration. There has to be changes applied to protractor to support the new stopSpecOnExpectationFailure jasmine node option. Please create an issue/feature request in Protractor issue tracker.


    I've also tried to call the throwOnExpectationFailure function, set the stopSpecOnExpectationFailure value throw jasmine.getEnv() in onPrepare() but none of that worked. Perhaps, I am missing something and there is a way to enable the setting.

    0 讨论(0)
提交回复
热议问题