{"id":15098877,"url":"https://github.com/ember-cli/ember-cli-chai","last_synced_at":"2025-10-08T03:31:51.958Z","repository":{"id":27419864,"uuid":"30897199","full_name":"ember-cli/ember-cli-chai","owner":"ember-cli","description":"Chai assertions for Ember.js","archived":true,"fork":false,"pushed_at":"2020-06-08T20:59:23.000Z","size":1310,"stargazers_count":21,"open_issues_count":0,"forks_count":9,"subscribers_count":9,"default_branch":"master","last_synced_at":"2024-12-28T06:35:38.822Z","etag":null,"topics":["chai","ember","ember-addon","ember-cli","javascript"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ember-cli.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-02-17T01:18:22.000Z","updated_at":"2024-05-30T02:52:30.000Z","dependencies_parsed_at":"2022-08-24T15:41:35.750Z","dependency_job_id":null,"html_url":"https://github.com/ember-cli/ember-cli-chai","commit_stats":null,"previous_names":[],"tags_count":19,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ember-cli%2Fember-cli-chai","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ember-cli%2Fember-cli-chai/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ember-cli%2Fember-cli-chai/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ember-cli%2Fember-cli-chai/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ember-cli","download_url":"https://codeload.github.com/ember-cli/ember-cli-chai/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":235678929,"owners_count":19028301,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["chai","ember","ember-addon","ember-cli","javascript"],"created_at":"2024-09-25T17:01:11.579Z","updated_at":"2025-10-08T03:31:46.614Z","avatar_url":"https://github.com/ember-cli.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\nember-cli-chai\n==============================================================================\n\n[![npm](https://img.shields.io/npm/v/ember-cli-chai.svg)](https://www.npmjs.com/package/ember-cli-chai)\n[![Build Status](https://travis-ci.org/ember-cli/ember-cli-chai.svg?branch=master)](https://travis-ci.org/ember-cli/ember-cli-chai)\n\n[Chai](http://chaijs.com/) assertions for [Ember.js](http://emberjs.com/).\n\nDeprecated\n------------------------------------------------------------------------------\n\nThis package is **deprecated**. Please use [ember-auto-import](https://github.com/ef4/ember-auto-import) to use chai and chai plugins directly. If you'd like to use chai, or were previously using ember-cli-chai, follow these instructions to use chai in your app:\n\nAdd `ember-auto-import` and `chai` to your project:\n\n`ember install ember-auto-import chai`\n\nNext, if you are using any plugins, add the following to `tests/test-helper.js` _before_ calling `start` from `ember-mocha` to ensure chai has loaded them:\n\n```javascript\n// tests/test-helper.js\nimport { start } from 'ember-mocha';\nimport chai from 'chai';\nimport chaiDom from 'chai-dom';\nchai.use(chaiDom);\nstart();\n```\n\n\nInstallation\n------------------------------------------------------------------------------\n\n```\nember install ember-cli-chai\n```\n\nUsage\n------------------------------------------------------------------------------\n\nAfter installing `ember-cli-chai` you can import [Chai](http://chaijs.com/)\nfrom the `chai` package:\n\n```js\nimport chai from 'chai';\n```\n\nor import the `expect()` function directly:\n\n```js\nimport { expect } from 'chai';\n```\n\nHave a look at the [vendor shim](vendor/shims/chai.js) file to understand\nwhat else can be imported this way.\n\n\n### QUnit\n\nPrevious versions of `ember-cli-chai` [supported QUnit](https://github.com/ember-cli/ember-cli-chai/pull/6)\nbut due to changes in `chai` itself this is unfortunately no longer viable.\nFor readable DOM assertions in QUnit we recommend [qunit-dom](https://github.com/simplabs/qunit-dom)\ninstead.\n\n\n### Chai plugins\n\n`ember-cli-chai` is able to automatically load a number of popular\n[Chai plugins](http://chaijs.com/plugins/):\n\n- [`chai-jquery`](https://github.com/chaijs/chai-jquery) – JQuery assertions\n- [`chai-dom`](https://github.com/nathanboktae/chai-dom) – DOM assertions\n- [`chai-as-promised`](https://github.com/domenic/chai-as-promised) – Promise assertions\n- [`sinon-chai`](https://github.com/domenic/sinon-chai) – Sinon assertions\n- [`testdouble-chai`](https://github.com/BaseCase/testdouble-chai) - testdouble.js assertions\n\nAll you have to do is install those plugins via `npm install --save-dev`.\nOnce they are installed and listed as dependencies in your `package.json` file\nthey will be used automatically.\n\nUsing `chai-jquery` for example will enable you to write JQuery assertions\nlike:\n\n```js\nexpect(find('.test-element')).to.have.text('hello');\n```\n\n\nLicense\n------------------------------------------------------------------------------\nember-cli-chai is licensed under the [MIT License](LICENSE.md).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fember-cli%2Fember-cli-chai","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fember-cli%2Fember-cli-chai","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fember-cli%2Fember-cli-chai/lists"}