Skip to content

Commit

Permalink
test: polyfill object.getownpropertydescriptors in decorators tests
Browse files Browse the repository at this point in the history
The polyfill is required by Node.js 6
  • Loading branch information
JLHwung committed Dec 21, 2020
1 parent 4f4570e commit 810f3db
Show file tree
Hide file tree
Showing 8 changed files with 198 additions and 91 deletions.
4 changes: 3 additions & 1 deletion packages/babel-plugin-proposal-decorators/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@
},
"devDependencies": {
"@babel/core": "workspace:*",
"@babel/helper-plugin-test-runner": "workspace:*"
"@babel/helper-plugin-test-runner": "workspace:*",
"babel-plugin-polyfill-es-shims": "0.0.8",
"object.getownpropertydescriptors": "^2.1.1"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
"presets": ["env"],
"plugins": [
["proposal-decorators", { "legacy": true }],
["proposal-class-properties", { "loose": true }]
["proposal-class-properties", { "loose": true }],
["babel-plugin-polyfill-es-shims", { "method": "usage-global", "targets": {
"node": "current"
}}]
]
}
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
"presets": ["env"],
"plugins": [
["proposal-decorators", { "legacy": true }],
["proposal-class-properties", { "loose": true }]
["proposal-class-properties", { "loose": true }],
["babel-plugin-polyfill-es-shims", { "method": "usage-global", "targets": {
"node": "current"
}}]
]
}
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
"presets": ["env"],
"plugins": [
["proposal-decorators", { "legacy": true }],
["proposal-class-properties", { "loose": true }]
["proposal-class-properties", { "loose": true }],
["babel-plugin-polyfill-es-shims", { "method": "usage-global", "targets": {
"node": "current"
}}]
]
}
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
"presets": ["env"],
"plugins": [
["proposal-decorators", { "legacy": true }],
["proposal-class-properties", { "loose": true }]
["proposal-class-properties", { "loose": true }],
["babel-plugin-polyfill-es-shims", { "method": "usage-global", "targets": {
"node": "current"
}}]
]
}
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
"presets": ["env"],
"plugins": [
["proposal-decorators", { "legacy": true }],
["proposal-class-properties", { "loose": true }]
["proposal-class-properties", { "loose": true }],
["babel-plugin-polyfill-es-shims", { "method": "usage-global", "targets": {
"node": "current"
}}]
]
}
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
"presets": ["env"],
"plugins": [
["proposal-decorators", { "legacy": true }],
["proposal-class-properties", { "loose": true }]
["proposal-class-properties", { "loose": true }],
["babel-plugin-polyfill-es-shims", { "method": "usage-global", "targets": {
"node": "current"
}}]
]
}

0 comments on commit 810f3db

Please sign in to comment.