aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Jarred Sumner <jarred@jarredsumner.com> 2022-02-04 00:58:12 -0800
committerGravatar Jarred Sumner <jarred@jarredsumner.com> 2022-02-04 00:58:12 -0800
commit735dc8f1d6063bde93e50142d5b3dcf6452d7d24 (patch)
tree475e47f5e925aca560ccc2b837ee2d65f4541de9
parenta9577c9ba8216455ae4563fbf707445bde7eb3eb (diff)
downloadbun-735dc8f1d6063bde93e50142d5b3dcf6452d7d24.tar.gz
bun-735dc8f1d6063bde93e50142d5b3dcf6452d7d24.tar.zst
bun-735dc8f1d6063bde93e50142d5b3dcf6452d7d24.zip
Add integration test for reading .json files that have UTF-8 string literals
Related: https://github.com/Jarred-Sumner/bun/issues/115
-rw-r--r--integration/snippets/package-json-utf8.js6
-rw-r--r--integration/snippets/utf8-package-json.json3
2 files changed, 9 insertions, 0 deletions
diff --git a/integration/snippets/package-json-utf8.js b/integration/snippets/package-json-utf8.js
new file mode 100644
index 000000000..a51fbb886
--- /dev/null
+++ b/integration/snippets/package-json-utf8.js
@@ -0,0 +1,6 @@
+import pkg from "./utf8-package-json.json";
+
+export function test() {
+ console.assert(!!pkg.author);
+ return testDone(import.meta.url);
+}
diff --git a/integration/snippets/utf8-package-json.json b/integration/snippets/utf8-package-json.json
new file mode 100644
index 000000000..aae7ce7b2
--- /dev/null
+++ b/integration/snippets/utf8-package-json.json
@@ -0,0 +1,3 @@
+{
+ "author": "Arnuad Barré (https://github.com/ArnaudBarre)"
+}