Hello,
I don't know what I have to write on the plugins/index.js files to get the chai-sorted plugin working.
website : http://www.chaijs.com/plugins/chai-sorted/
Can you help please ? : )
Best regard
Your tests and chai run in the browser, so chai plugins need to be configured there instead of the plugins file, which is run in the background Node.js process.
I haven't tested this out, but the following should work if you add it to support/index.js:
import chaiSorted from "chai-sorted"
chai.use(chaiSorted)
We're working on improving the docs around extending Cypress, so we'll try to make this clearer in the process.
@chrisbreiding solution worked like a charm for me installing chai-subset, thank you!
Most helpful comment
Your tests and chai run in the browser, so chai plugins need to be configured there instead of the plugins file, which is run in the background Node.js process.
I haven't tested this out, but the following should work if you add it to
support/index.js:We're working on improving the docs around extending Cypress, so we'll try to make this clearer in the process.