Skip to content

armgit / zulip

Public Imported from GitHub
0

Zulip server and web application. Open-source team chat that helps teams stay productive and focused.

tests: Use make_stream in compose_paste tests.

Tanuj kinkar52000f9b7ff4
diff --git a/web/tests/compose_paste.test.cjs b/web/tests/compose_paste.test.cjs
index 581bfa4f63e..5f3c461bebc 100644
--- a/web/tests/compose_paste.test.cjs
+++ b/web/tests/compose_paste.test.cjs
@@ -7,6 +7,7 @@ const {JSDOM} = require("jsdom");
const katex_tests = require("../../zerver/tests/fixtures/katex_test_cases.json");
const {parse} = require("../src/markdown.ts");
+const {make_stream} = require("./lib/example_stream.cjs");
const {mock_esm, zrequire, set_global} = require("./lib/namespace.cjs");
const {run_test, noop} = require("./lib/test.cjs");
const $ = require("./lib/zjquery.cjs");
@@ -37,14 +38,18 @@ initialize_user_settings({
});
markdown.initialize(markdown_config.get_helpers());
-stream_data.add_sub_for_tests({
- stream_id: 4,
- name: "Rome",
-});
-stream_data.add_sub_for_tests({
- stream_id: 5,
- name: "Romeo`s lair",
-});
+stream_data.add_sub_for_tests(
+ make_stream({
+ stream_id: 4,
+ name: "Rome",
+ }),
+);
+stream_data.add_sub_for_tests(
+ make_stream({
+ stream_id: 5,
+ name: "Romeo`s lair",
+ }),
+);
run_test("try_stream_topic_syntax_text", () => {
const test_cases = [