Javascript 带chai(量角器框架)的软断言

Javascript 带chai(量角器框架)的软断言,javascript,protractor,mocha.js,chai,cucumberjs,Javascript,Protractor,Mocha.js,Chai,Cucumberjs,@全部:- 我已经创建了Cucumber+量角器框架来测试我的基于web的应用程序,但是我遇到了一个问题,由于这个问题,我无法进一步进行 *我使用柴作为断言库 如果我的断言在任何一个步骤中失败,那么下一个步骤将不会执行,并且我的框架将退出。请帮助我,让我知道如何处理这个场景,或者如何使用chai添加软断言 .功能文件:- Scenario: Verify abc journey Given Open the site "https://www.abc.in"

@全部:- 我已经创建了Cucumber+量角器框架来测试我的基于web的应用程序,但是我遇到了一个问题,由于这个问题,我无法进一步进行

*我使用柴作为断言库

如果我的断言在任何一个步骤中失败,那么下一个步骤将不会执行,并且我的框架将退出。请帮助我,让我知道如何处理这个场景,或者如何使用chai添加软断言

.功能文件:-

Scenario: Verify abc journey
        Given Open the site "https://www.abc.in"
        Then Verify the site title "abc"
        Then user validates the captcha image
.js文件:-

Given(/^Open the site "([^"]*)"$/, async function (site) {   
   browser.get(site);
  
    await  config.waitElement(element(by.xpath("//span[text()='abc12']")),3000)   
  .catch(()=>expect(true).to.equal(false))  
  });
  
  Then(/^Verify the site title "([^"]*)"$/,{timeout: 2 * 5000}, async function (title) { 

      console.log(await browser.getTitle()+" and title is  " +title);    
   
  });
由于.catch(()=>expect(true).to.equal(false))断言,我的框架停止,但我希望错误应该出现,如果断言失败,但还需要执行下一步。 请帮助,如何应用软断言与柴