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

RFC: Revamp TestUtils & tests #14

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/nodejs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:

strategy:
matrix:
node-version: [10.x, 12.x]
node-version: [14.x]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should probably add 16 since it's the current LTS release.


steps:
- uses: actions/checkout@v2
Expand Down
4 changes: 2 additions & 2 deletions bsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@
"name": "@rescript/react",
"reason": { "react-jsx": 3 },
"sources": [
{"dir": "src", "subdirs": true},
{ "dir": "src", "subdirs": true },
{ "dir": "test", "type": "dev" }
],
"package-specs": [{ "module": "commonjs", "in-source": true }],
"suffix": ".bs.js",
"bs-dev-dependencies": ["reason-test-framework"],
"bs-dev-dependencies": ["rescript-test"],
"bsc-flags": []
}
4,617 changes: 341 additions & 4,276 deletions package-lock.json

Large diffs are not rendered by default.

31 changes: 8 additions & 23 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
"build": "bsb -make-world",
"start": "bsb -make-world -w",
"clean": "bsb -clean-world",
"test": "echo 'tests disabled for now'"
"test": "retest --with-dom test/*.bs.js"
},
"keywords": [
"rescript",
Expand All @@ -28,29 +28,14 @@
},
"homepage": "https://rescript-lang.org/docs/react/latest/introduction",
"devDependencies": {
"bs-platform": "8.3.0",
"jest": "^26.0.1",
"react": "^16.8.1",
"react-dom": "^16.8.1",
"reason-test-framework": "^0.3.2"
"bs-platform": "^8.4.0",
"react": "^17.0.0",
"react-dom": "^17.0.0",
"rescript-test": "^2.0.5"
},
"peerDependencies": {
"bs-platform": "^8.3.0",
"react": "^16.8.1",
"react-dom": "^16.8.1"
},
"jest": {
"moduleDirectories": [
"node_modules"
],
"roots": [
"test"
],
"testMatch": [
"**/*__test.bs.js"
],
"transformIgnorePatterns": [
"node_modules/(?!(bs-platform|reason-react|reason-react-compat|reason-react-update|bs-webapi|bs-css|bs-css-emotion|reason-test-framework)/)"
]
"bs-platform": ">=8.3.0",
"react": ">=16.8.1",
"react-dom": ">=16.8.1"
}
}
463 changes: 338 additions & 125 deletions src/ReactTestUtils.res

Large diffs are not rendered by default.

386 changes: 338 additions & 48 deletions src/ReactTestUtils.resi

Large diffs are not rendered by default.

Loading