{
  "doc": {
    "id": "app/references/bundled-libraries",
    "title": "Bundled Libraries in Cypress",
    "description": "Open source testing libraries bundled with Cypress",
    "section": "app",
    "source_path": "/llm/markdown/app/references/bundled-libraries.md",
    "version": "e6988a974973e9090ce70406c38cb2b9e0eac9fa",
    "updated_at": "2026-05-15T15:50:22.536Z",
    "headings": [
      {
        "id": "app/references/bundled-libraries#bundled-libraries",
        "text": "Bundled Libraries",
        "level": 1
      },
      {
        "id": "app/references/bundled-libraries#mocha",
        "text": "Mocha",
        "level": 2
      },
      {
        "id": "app/references/bundled-libraries#chai",
        "text": "Chai",
        "level": 2
      },
      {
        "id": "app/references/bundled-libraries#chai-jquery",
        "text": "Chai-jQuery",
        "level": 2
      },
      {
        "id": "app/references/bundled-libraries#sinon-js",
        "text": "Sinon.js",
        "level": 2
      },
      {
        "id": "app/references/bundled-libraries#sinon-chai",
        "text": "Sinon-Chai",
        "level": 2
      },
      {
        "id": "app/references/bundled-libraries#other-library-utilities",
        "text": "Other Library Utilities",
        "level": 2
      }
    ]
  },
  "chunks": [
    {
      "id": "app/references/bundled-libraries#mocha",
      "doc_id": "app/references/bundled-libraries",
      "heading": "Mocha",
      "heading_level": 2,
      "content_markdown": "## Mocha\n\n[http://mochajs.org/](http://mochajs.org/)\n\nCypress has adopted Mocha's `bdd` syntax, which fits perfectly with both integration and unit testing. All of the tests you'll be writing sit on the fundamental harness Mocha provides, namely:\n\n*   [`describe()`](http://mochajs.org/#bdd)\n*   [`context()`](http://mochajs.org/#bdd)\n*   [`it()`](http://mochajs.org/#bdd)\n*   [`before()`](http://mochajs.org/#hooks)\n*   [`beforeEach()`](http://mochajs.org/#hooks)\n*   [`afterEach()`](http://mochajs.org/#hooks)\n*   [`after()`](http://mochajs.org/#hooks)\n*   [`.only()`](http://mochajs.org/#exclusive-tests)\n*   [`.skip()`](http://mochajs.org/#exclusive-tests)\n\nAdditionally, Mocha gives us excellent [`async` support](http://mochajs.org/#asynchronous-code). Cypress has extended Mocha, sanding off the rough edges, weird edge cases, bugs, and error messages. These fixes are all completely transparent.\n\n[Check out our guide to writing and organizing tests.](/llm/markdown/app/core-concepts/writing-and-organizing-tests.md)\n",
      "section": "app",
      "anchors": [
        "mocha"
      ],
      "path": "/llm/json/chunked/app/references/bundled-libraries.json",
      "token_estimate": 119
    },
    {
      "id": "app/references/bundled-libraries#chai",
      "doc_id": "app/references/bundled-libraries",
      "heading": "Chai",
      "heading_level": 2,
      "content_markdown": "## Chai\n\n[http://chaijs.com/](http://chaijs.com/)\n\nWhile Mocha provides us a framework to structure our tests, Chai gives us the ability to easily write assertions. Chai gives us readable assertions with excellent error messages. Cypress extends this, fixes several common pitfalls, and wraps Chai's DSL using [subjects](/llm/markdown/app/core-concepts/introduction-to-cypress.md#Assertions) and the [`.should()`](/llm/markdown/api/commands/should.md) command.\n\n[List of available Chai Assertions](/llm/markdown/app/references/assertions.md#Chai)\n",
      "section": "app",
      "anchors": [
        "chai"
      ],
      "path": "/llm/json/chunked/app/references/bundled-libraries.json",
      "token_estimate": 71
    },
    {
      "id": "app/references/bundled-libraries#chai-jquery",
      "doc_id": "app/references/bundled-libraries",
      "heading": "Chai-jQuery",
      "heading_level": 2,
      "content_markdown": "## Chai-jQuery\n\n[https://github.com/chaijs/chai-jquery](https://github.com/chaijs/chai-jquery)\n\nWhen writing integration tests, you will likely work a lot with the DOM. Cypress brings in Chai-jQuery, which automatically extends Chai with specific jQuery chainer methods.\n\n[List of available Chai-jQuery Assertions](/llm/markdown/app/references/assertions.md#Chai-jQuery)\n",
      "section": "app",
      "anchors": [
        "chai-jquery"
      ],
      "path": "/llm/json/chunked/app/references/bundled-libraries.json",
      "token_estimate": 45
    },
    {
      "id": "app/references/bundled-libraries#sinon-js",
      "doc_id": "app/references/bundled-libraries",
      "heading": "Sinon.js",
      "heading_level": 2,
      "content_markdown": "## Sinon.js\n\n[https://github.com/sinonjs/sinon](https://github.com/sinonjs/sinon)\n\nWhen writing unit tests, or even in integration-like tests, you often need to ability to stub and spy methods. Cypress includes two methods, [`cy.stub()`](/llm/markdown/api/commands/stub.md) and [`cy.spy()`](/llm/markdown/api/commands/spy.md) that return Sinon stubs and spies, respectively.\n\nCypress also exposes a utility so that `sinon` can be called anywhere inside of your tests using [`Cypress.sinon`](/llm/markdown/api/utilities/sinon.md).\n\n[Check out our guide for working with spies, stubs, and clocks.](/llm/markdown/app/guides/stubs-spies-and-clocks.md)\n",
      "section": "app",
      "anchors": [
        "sinon-js"
      ],
      "path": "/llm/json/chunked/app/references/bundled-libraries.json",
      "token_estimate": 87
    },
    {
      "id": "app/references/bundled-libraries#sinon-chai",
      "doc_id": "app/references/bundled-libraries",
      "heading": "Sinon-Chai",
      "heading_level": 2,
      "content_markdown": "## Sinon-Chai\n\n[https://github.com/cypress-io/sinon-chai](https://github.com/cypress-io/sinon-chai)\n\nWhen working with `stubs` or `spies` you'll regularly want to use those when writing Chai assertions. Cypress bundles in Sinon-Chai which extends Chai allowing you to [write assertions](https://github.com/cypress-io/sinon-chai) about `stubs` and `spies`.\n\n[List of available Sinon-Chai Assertions](/llm/markdown/app/references/assertions.md#Sinon-Chai)\n",
      "section": "app",
      "anchors": [
        "sinon-chai"
      ],
      "path": "/llm/json/chunked/app/references/bundled-libraries.json",
      "token_estimate": 53
    },
    {
      "id": "app/references/bundled-libraries#other-library-utilities",
      "doc_id": "app/references/bundled-libraries",
      "heading": "Other Library Utilities",
      "heading_level": 2,
      "content_markdown": "## Other Library Utilities\n\nCypress also bundles the following tools on the `Cypress` object. These can be used anywhere inside of your tests.\n\n*   [`Cypress._`](/llm/markdown/api/utilities/_.md) (lodash)\n*   [`Cypress.$`](/llm/markdown/api/utilities/$.md) (jQuery)\n*   [`Cypress.minimatch`](/llm/markdown/api/utilities/minimatch.md) (minimatch.js)\n*   [`Cypress.Blob`](/llm/markdown/api/utilities/blob.md) (Blob utils)\n*   [`Cypress.Buffer`](/llm/markdown/api/utilities/buffer.md) (Buffer utils)\n*   [`Cypress.Promise`](/llm/markdown/api/utilities/promise.md) (Bluebird)\n",
      "section": "app",
      "anchors": [
        "other-library-utilities"
      ],
      "path": "/llm/json/chunked/app/references/bundled-libraries.json",
      "token_estimate": 57
    }
  ]
}