Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create @wordpress/test-utils package #18855

Closed
wants to merge 14 commits into from
Closed
1 change: 1 addition & 0 deletions bin/update-readmes.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ const packages = [
'redux-routine',
'rich-text',
'shortcode',
'test-utils',
'url',
'viewport',
'wordcount',
Expand Down
6 changes: 6 additions & 0 deletions docs/manifest-devhub.json
Original file line number Diff line number Diff line change
Expand Up @@ -1427,6 +1427,12 @@
"markdown_source": "../packages/shortcode/README.md",
"parent": "packages"
},
{
"title": "@wordpress/test-utils",
"slug": "packages-test-utils",
"markdown_source": "../packages/test-utils/README.md",
"parent": "packages"
},
{
"title": "@wordpress/token-list",
"slug": "packages-token-list",
Expand Down
216 changes: 214 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,7 @@
"@wordpress/npm-package-json-lint-config": "file:packages/npm-package-json-lint-config",
"@wordpress/postcss-themes": "file:packages/postcss-themes",
"@wordpress/scripts": "file:packages/scripts",
"@wordpress/test-utils": "file:packages/test-utils",
"babel-loader": "8.0.6",
"babel-plugin-emotion": "10.0.23",
"babel-plugin-inline-json-import": "0.3.2",
Expand Down
6 changes: 6 additions & 0 deletions packages/jest-preset-default/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
## master

### New Features

- Add `@wordpress/test-utils/extend-expect` to Jest setup ([18855](https://github.com/WordPress/gutenberg/pull/18855)).

## 5.1.0 (2019-09-03)

### Bug Fixes
Expand Down
3 changes: 2 additions & 1 deletion packages/jest-preset-default/jest-preset.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@
"<rootDir>/node_modules/@wordpress/jest-preset-default/scripts/setup-globals.js"
],
"setupFilesAfterEnv": [
"<rootDir>/node_modules/@wordpress/jest-preset-default/scripts/setup-test-framework.js"
"<rootDir>/node_modules/@wordpress/jest-preset-default/scripts/setup-test-framework.js",
"<rootDir>/node_modules/@wordpress/test-utils/extend-expect"
],
"snapshotSerializers": [
"<rootDir>/node_modules/enzyme-to-json/serializer.js"
Expand Down
1 change: 1 addition & 0 deletions packages/jest-preset-default/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@
"main": "index.js",
"dependencies": {
"@wordpress/jest-console": "file:../jest-console",
"@wordpress/test-utils": "file:../test-utils",
"babel-jest": "^24.7.1",
"enzyme": "^3.9.0",
"enzyme-adapter-react-16": "^1.10.0",
Expand Down
1 change: 1 addition & 0 deletions packages/test-utils/.npmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
package-lock=false
1 change: 1 addition & 0 deletions packages/test-utils/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
## master
Loading