Zulip server and web application. Open-source team chat that helps teams stay productive and focused.
node_tests: Replace `set_global` with `mock_esm` in example4.js.
Dinesh54daeadbd6d0
diff --git a/frontend_tests/node_tests/example3.js b/frontend_tests/node_tests/example3.jsindex e1aaafca822..5551d8849e6 100644--- a/frontend_tests/node_tests/example3.js+++ b/frontend_tests/node_tests/example3.js@@ -16,7 +16,7 @@ const stream_data = zrequire("stream_data");// This is the first time we have to deal with page_params.// page_params has a lot of important data shared by various-// modules. Most of the data is irrelevant to out tests.+// modules. Most of the data is irrelevant to our tests.// Use this to explicitly say we are not a special Zephyr// realm, since we want to test the "normal" codepath.page_params.realm_is_zephyr_mirror_realm = false;diff --git a/frontend_tests/node_tests/example4.js b/frontend_tests/node_tests/example4.jsindex 8cd9e2c85c3..b4adf20d82b 100644--- a/frontend_tests/node_tests/example4.js+++ b/frontend_tests/node_tests/example4.js@@ -29,7 +29,7 @@ const {run_test} = require("../zjsunit/test");We can quickly review some testing concepts:zrequire - bring in real code- set_global - create stubs+ mock_esm - mock es6 modulesassert.equal - verify results------