{"id":26332837,"url":"https://github.com/danielhreben/jest-matcher-specific-error","last_synced_at":"2025-03-15T23:31:30.883Z","repository":{"id":42824520,"uuid":"257213403","full_name":"DanielHreben/jest-matcher-specific-error","owner":"DanielHreben","description":"Make sure your function really throws what you expect","archived":false,"fork":false,"pushed_at":"2024-01-24T10:32:03.000Z","size":402,"stargazers_count":25,"open_issues_count":5,"forks_count":5,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-09T08:02:08.266Z","etag":null,"topics":["error","expect","jest","matcher","throw"],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","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/DanielHreben.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-04-20T08:08:17.000Z","updated_at":"2024-01-28T20:03:39.000Z","dependencies_parsed_at":"2024-06-18T16:58:31.448Z","dependency_job_id":null,"html_url":"https://github.com/DanielHreben/jest-matcher-specific-error","commit_stats":{"total_commits":24,"total_committers":3,"mean_commits":8.0,"dds":"0.41666666666666663","last_synced_commit":"2e07b8ffc1f129e43b3bf8318480b5264e9c3aac"},"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DanielHreben%2Fjest-matcher-specific-error","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DanielHreben%2Fjest-matcher-specific-error/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DanielHreben%2Fjest-matcher-specific-error/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DanielHreben%2Fjest-matcher-specific-error/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/DanielHreben","download_url":"https://codeload.github.com/DanielHreben/jest-matcher-specific-error/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243806122,"owners_count":20350773,"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":["error","expect","jest","matcher","throw"],"created_at":"2025-03-15T23:30:52.890Z","updated_at":"2025-03-15T23:31:30.874Z","avatar_url":"https://github.com/DanielHreben.png","language":"TypeScript","readme":"# jest-matcher-specific-error\nMake sure your function really throws what you expect\n\nWorkaround for https://github.com/facebook/jest/issues/8140\n\n# Installation\nWith npm:\n\u003e npm install --save-dev jest-matcher-specific-error\n\nWith yarn:\n\u003e yarn add -D jest-matcher-specific-error\n\n# Setup\nSame as [Other Jest matchers](https://jest-extended.jestcommunity.dev/docs/getting-started/setup).\n\n# Typescript\n\nSame as [Other Jest matchers](https://jest-extended.jestcommunity.dev/docs/getting-started/typescript).\n\n# Usage\n```typescript\nawait expect(yourPromise).rejects.toMatchError(expectedError);\nawait expect(yourFunction).rejects.toMatchError(expectedError);\nexpect(yourError).toMatchError(expectedError);\n```\n\n# Match logic\nErrors threated as equal if ALL conditions satisfied:\n * Errors are instances of same class (strict `===` comparison by reference)\n * Error messages are equal\n * All error public fields are deeply equal (default `jest` helper comparison)\n\nError stack traces are ignored.\n\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdanielhreben%2Fjest-matcher-specific-error","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdanielhreben%2Fjest-matcher-specific-error","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdanielhreben%2Fjest-matcher-specific-error/lists"}