aboutsummaryrefslogtreecommitdiff
path: root/test/compress
diff options
context:
space:
mode:
authorAlex Lam S.L <alexlamsl@gmail.com>2020-08-18 23:14:41 +0100
committerGitHub <noreply@github.com>2020-08-19 06:14:41 +0800
commite8db526f513ba324535fff040d651d4faacd89ae (patch)
treecf3cbd49f37c85a8c649fdcaa9265dadceb7f543 /test/compress
parentfa13ed439138f9652ccb045e04965d336de0fd70 (diff)
downloadtracifyjs-e8db526f513ba324535fff040d651d4faacd89ae.tar.gz
tracifyjs-e8db526f513ba324535fff040d651d4faacd89ae.zip
avoid setters during `console.log()` in sandbox (#4055)
fixes #4054
Diffstat (limited to 'test/compress')
-rw-r--r--test/compress/sandbox.js18
1 files changed, 18 insertions, 0 deletions
diff --git a/test/compress/sandbox.js b/test/compress/sandbox.js
index 02097c1e..9356f6f3 100644
--- a/test/compress/sandbox.js
+++ b/test/compress/sandbox.js
@@ -80,3 +80,21 @@ log_global: {
}
expect_stdout: "[object global]"
}
+
+issue_4054: {
+ input: {
+ console.log({
+ set p(v) {
+ throw "FAIL";
+ },
+ });
+ }
+ expect: {
+ console.log({
+ set p(v) {
+ throw "FAIL";
+ },
+ });
+ }
+ expect_stdout: "{ p: [Setter] }"
+}