Open History to see the last commit
1import * as NodeServices from "@effect/platform-node/NodeServices";
2import { assert, it } from "@effect/vitest";
3import { assertSuccess } from "@effect/vitest/utils";
4import { FileSystem, Path, Effect } from "effect";
5
6import {
7 isCommandAvailable,
8 launchDetached,
9 resolveAvailableEditors,
10 resolveEditorLaunch,
11} from "./open.ts";
12
13it.layer(NodeServices.layer)("resolveEditorLaunch", (it) => {
14 it.effect("returns commands for command-based editors", () =>
15 Effect.gen(function* () {
16 const antigravityLaunch = yield* resolveEditorLaunch(
17 { cwd: "/tmp/workspace", editor: "antigravity" },
18 "darwin",
19 { PATH: "" },
20 );
21 assert.deepEqual(antigravityLaunch, {
22 command: "agy",
23 args: ["/tmp/workspace"],
24 });
25
26 const cursorLaunch = yield* resolveEditorLaunch(
27 { cwd: "/tmp/workspace", editor: "cursor" },
28 "darwin",
29 { PATH: "" },
30 );
31 assert.deepEqual(cursorLaunch, {
32 command: "cursor",
33 args: ["/tmp/workspace"],
34 });
35
36 const traeLaunch = yield* resolveEditorLaunch(
37 { cwd: "/tmp/workspace", editor: "trae" },
38 "darwin",
39 );
40 assert.deepEqual(traeLaunch, {
41 command: "trae",
42 args: ["/tmp/workspace"],
43 });
44
45 const kiroLaunch = yield* resolveEditorLaunch(
46 { cwd: "/tmp/workspace", editor: "kiro" },
47 "darwin",
48 { PATH: "" },
49 );
50 assert.deepEqual(kiroLaunch, {
51 command: "kiro",
52 args: ["ide", "/tmp/workspace"],
53 });
54
55 const vscodeLaunch = yield* resolveEditorLaunch(
56 { cwd: "/tmp/workspace", editor: "vscode" },
57 "darwin",
58 { PATH: "" },
59 );
60 assert.deepEqual(vscodeLaunch, {
61 command: "code",
62 args: ["/tmp/workspace"],
63 });
64
65 const vscodeInsidersLaunch = yield* resolveEditorLaunch(
66 { cwd: "/tmp/workspace", editor: "vscode-insiders" },
67 "darwin",
68 );
69 assert.deepEqual(vscodeInsidersLaunch, {
70 command: "code-insiders",
71 args: ["/tmp/workspace"],
72 });
73
74 const vscodiumLaunch = yield* resolveEditorLaunch(
75 { cwd: "/tmp/workspace", editor: "vscodium" },
76 "darwin",
77 );
78 assert.deepEqual(vscodiumLaunch, {
79 command: "codium",
80 args: ["/tmp/workspace"],
81 });
82
83 const zedLaunch = yield* resolveEditorLaunch(
84 { cwd: "/tmp/workspace", editor: "zed" },
85 "darwin",
86 { PATH: "" },
87 );
88 assert.deepEqual(zedLaunch, {
89 command: "zed",
90 args: ["/tmp/workspace"],
91 });
92
93 const ideaLaunch = yield* resolveEditorLaunch(
94 { cwd: "/tmp/workspace", editor: "idea" },
95 "darwin",
96 );
97 assert.deepEqual(ideaLaunch, {
98 command: "idea",
99 args: ["/tmp/workspace"],
100 });
101
102 const aquaLaunch = yield* resolveEditorLaunch(
103 { cwd: "/tmp/workspace", editor: "aqua" },
104 "darwin",
105 );
106 assert.deepEqual(aquaLaunch, {
107 command: "aqua",
108 args: ["/tmp/workspace"],
109 });
110
111 const clionLaunch = yield* resolveEditorLaunch(
112 { cwd: "/tmp/workspace", editor: "clion" },
113 "darwin",
114 );
115 assert.deepEqual(clionLaunch, {
116 command: "clion",
117 args: ["/tmp/workspace"],
118 });
119
120 const datagripLaunch = yield* resolveEditorLaunch(
121 { cwd: "/tmp/workspace", editor: "datagrip" },
122 "darwin",
123 );
124 assert.deepEqual(datagripLaunch, {
125 command: "datagrip",
126 args: ["/tmp/workspace"],
127 });
128
129 const dataspellLaunch = yield* resolveEditorLaunch(
130 { cwd: "/tmp/workspace", editor: "dataspell" },
131 "darwin",
132 );
133 assert.deepEqual(dataspellLaunch, {
134 command: "dataspell",
135 args: ["/tmp/workspace"],
136 });
137
138 const golandLaunch = yield* resolveEditorLaunch(
139 { cwd: "/tmp/workspace", editor: "goland" },
140 "darwin",
141 );
142 assert.deepEqual(golandLaunch, {
143 command: "goland",
144 args: ["/tmp/workspace"],
145 });
146
147 const phpstormLaunch = yield* resolveEditorLaunch(
148 { cwd: "/tmp/workspace", editor: "phpstorm" },
149 "darwin",
150 );
151 assert.deepEqual(phpstormLaunch, {
152 command: "phpstorm",
153 args: ["/tmp/workspace"],
154 });
155
156 const pycharmLaunch = yield* resolveEditorLaunch(
157 { cwd: "/tmp/workspace", editor: "pycharm" },
158 "darwin",
159 );
160 assert.deepEqual(pycharmLaunch, {
161 command: "pycharm",
162 args: ["/tmp/workspace"],
163 });
164
165 const riderLaunch = yield* resolveEditorLaunch(
166 { cwd: "/tmp/workspace", editor: "rider" },
167 "darwin",
168 );
169 assert.deepEqual(riderLaunch, {
170 command: "rider",
171 args: ["/tmp/workspace"],
172 });
173
174 const rubymineLaunch = yield* resolveEditorLaunch(
175 { cwd: "/tmp/workspace", editor: "rubymine" },
176 "darwin",
177 );
178 assert.deepEqual(rubymineLaunch, {
179 command: "rubymine",
180 args: ["/tmp/workspace"],
181 });
182
183 const rustroverLaunch = yield* resolveEditorLaunch(
184 { cwd: "/tmp/workspace", editor: "rustrover" },
185 "darwin",
186 );
187 assert.deepEqual(rustroverLaunch, {
188 command: "rustrover",
189 args: ["/tmp/workspace"],
190 });
191
192 const webstormLaunch = yield* resolveEditorLaunch(
193 { cwd: "/tmp/workspace", editor: "webstorm" },
194 "darwin",
195 );
196 assert.deepEqual(webstormLaunch, {
197 command: "webstorm",
198 args: ["/tmp/workspace"],
199 });
200 }),
201 );
202
203 it.effect("applies launch-style-specific navigation arguments", () =>
204 Effect.gen(function* () {
205 const lineOnly = yield* resolveEditorLaunch(
206 { cwd: "/tmp/workspace/AGENTS.md:48", editor: "cursor" },
207 "darwin",
208 { PATH: "" },
209 );
210 assert.deepEqual(lineOnly, {
211 command: "cursor",
212 args: ["--goto", "/tmp/workspace/AGENTS.md:48"],
213 });
214
215 const lineAndColumn = yield* resolveEditorLaunch(
216 { cwd: "/tmp/workspace/src/open.ts:71:5", editor: "cursor" },
217 "darwin",
218 { PATH: "" },
219 );
220 assert.deepEqual(lineAndColumn, {
221 command: "cursor",
222 args: ["--goto", "/tmp/workspace/src/open.ts:71:5"],
223 });
224
225 const traeLineAndColumn = yield* resolveEditorLaunch(
226 { cwd: "/tmp/workspace/src/open.ts:71:5", editor: "trae" },
227 "darwin",
228 );
229 assert.deepEqual(traeLineAndColumn, {
230 command: "trae",
231 args: ["--goto", "/tmp/workspace/src/open.ts:71:5"],
232 });
233
234 const kiroLineAndColumn = yield* resolveEditorLaunch(
235 { cwd: "/tmp/workspace/src/open.ts:71:5", editor: "kiro" },
236 "darwin",
237 { PATH: "" },
238 );
239 assert.deepEqual(kiroLineAndColumn, {
240 command: "kiro",
241 args: ["ide", "--goto", "/tmp/workspace/src/open.ts:71:5"],
242 });
243
244 const vscodeLineAndColumn = yield* resolveEditorLaunch(
245 { cwd: "/tmp/workspace/src/open.ts:71:5", editor: "vscode" },
246 "darwin",
247 { PATH: "" },
248 );
249 assert.deepEqual(vscodeLineAndColumn, {
250 command: "code",
251 args: ["--goto", "/tmp/workspace/src/open.ts:71:5"],
252 });
253
254 const vscodeInsidersLineAndColumn = yield* resolveEditorLaunch(
255 { cwd: "/tmp/workspace/src/open.ts:71:5", editor: "vscode-insiders" },
256 "darwin",
257 );
258 assert.deepEqual(vscodeInsidersLineAndColumn, {
259 command: "code-insiders",
260 args: ["--goto", "/tmp/workspace/src/open.ts:71:5"],
261 });
262
263 const vscodiumLineAndColumn = yield* resolveEditorLaunch(
264 { cwd: "/tmp/workspace/src/open.ts:71:5", editor: "vscodium" },
265 "darwin",
266 );
267 assert.deepEqual(vscodiumLineAndColumn, {
268 command: "codium",
269 args: ["--goto", "/tmp/workspace/src/open.ts:71:5"],
270 });
271
272 const zedLineAndColumn = yield* resolveEditorLaunch(
273 { cwd: "/tmp/workspace/src/open.ts:71:5", editor: "zed" },
274 "darwin",
275 { PATH: "" },
276 );
277 assert.deepEqual(zedLineAndColumn, {
278 command: "zed",
279 args: ["/tmp/workspace/src/open.ts:71:5"],
280 });
281
282 const zedLineOnly = yield* resolveEditorLaunch(
283 { cwd: "/tmp/workspace/AGENTS.md:48", editor: "zed" },
284 "darwin",
285 { PATH: "" },
286 );
287 assert.deepEqual(zedLineOnly, {
288 command: "zed",
289 args: ["/tmp/workspace/AGENTS.md:48"],
290 });
291
292 const ideaLineOnly = yield* resolveEditorLaunch(
293 { cwd: "/tmp/workspace/AGENTS.md:48", editor: "idea" },
294 "darwin",
295 );
296 assert.deepEqual(ideaLineOnly, {
297 command: "idea",
298 args: ["--line", "48", "/tmp/workspace/AGENTS.md"],
299 });
300
301 const ideaLineAndColumn = yield* resolveEditorLaunch(
302 { cwd: "/tmp/workspace/src/open.ts:71:5", editor: "idea" },
303 "darwin",
304 );
305 assert.deepEqual(ideaLineAndColumn, {
306 command: "idea",
307 args: ["--line", "71", "--column", "5", "/tmp/workspace/src/open.ts"],
308 });
309
310 const aquaLineAndColumn = yield* resolveEditorLaunch(
311 { cwd: "/tmp/workspace/src/open.ts:71:5", editor: "aqua" },
312 "darwin",
313 );
314 assert.deepEqual(aquaLineAndColumn, {
315 command: "aqua",
316 args: ["--line", "71", "--column", "5", "/tmp/workspace/src/open.ts"],
317 });
318
319 const clionLineAndColumn = yield* resolveEditorLaunch(
320 { cwd: "/tmp/workspace/src/open.ts:71:5", editor: "clion" },
321 "darwin",
322 );
323 assert.deepEqual(clionLineAndColumn, {
324 command: "clion",
325 args: ["--line", "71", "--column", "5", "/tmp/workspace/src/open.ts"],
326 });
327
328 const datagripLineAndColumn = yield* resolveEditorLaunch(
329 { cwd: "/tmp/workspace/src/open.ts:71:5", editor: "datagrip" },
330 "darwin",
331 );
332 assert.deepEqual(datagripLineAndColumn, {
333 command: "datagrip",
334 args: ["--line", "71", "--column", "5", "/tmp/workspace/src/open.ts"],
335 });
336
337 const dataspellLineAndColumn = yield* resolveEditorLaunch(
338 { cwd: "/tmp/workspace/src/open.ts:71:5", editor: "dataspell" },
339 "darwin",
340 );
341 assert.deepEqual(dataspellLineAndColumn, {
342 command: "dataspell",
343 args: ["--line", "71", "--column", "5", "/tmp/workspace/src/open.ts"],
344 });
345
346 const golandLineAndColumn = yield* resolveEditorLaunch(
347 { cwd: "/tmp/workspace/src/open.ts:71:5", editor: "goland" },
348 "darwin",
349 );
350 assert.deepEqual(golandLineAndColumn, {
351 command: "goland",
352 args: ["--line", "71", "--column", "5", "/tmp/workspace/src/open.ts"],
353 });
354
355 const phpstormLineAndColumn = yield* resolveEditorLaunch(
356 { cwd: "/tmp/workspace/src/open.ts:71:5", editor: "phpstorm" },
357 "darwin",
358 );
359 assert.deepEqual(phpstormLineAndColumn, {
360 command: "phpstorm",
361 args: ["--line", "71", "--column", "5", "/tmp/workspace/src/open.ts"],
362 });
363
364 const pycharmLineAndColumn = yield* resolveEditorLaunch(
365 { cwd: "/tmp/workspace/src/open.ts:71:5", editor: "pycharm" },
366 "darwin",
367 );
368 assert.deepEqual(pycharmLineAndColumn, {
369 command: "pycharm",
370 args: ["--line", "71", "--column", "5", "/tmp/workspace/src/open.ts"],
371 });
372
373 const riderLineAndColumn = yield* resolveEditorLaunch(
374 { cwd: "/tmp/workspace/src/open.ts:71:5", editor: "rider" },
375 "darwin",
376 );
377 assert.deepEqual(riderLineAndColumn, {
378 command: "rider",
379 args: ["--line", "71", "--column", "5", "/tmp/workspace/src/open.ts"],
380 });
381
382 const rubymineLineAndColumn = yield* resolveEditorLaunch(
383 { cwd: "/tmp/workspace/src/open.ts:71:5", editor: "rubymine" },
384 "darwin",
385 );
386 assert.deepEqual(rubymineLineAndColumn, {
387 command: "rubymine",
388 args: ["--line", "71", "--column", "5", "/tmp/workspace/src/open.ts"],
389 });
390
391 const rustroverLineAndColumn = yield* resolveEditorLaunch(
392 { cwd: "/tmp/workspace/src/open.ts:71:5", editor: "rustrover" },
393 "darwin",
394 );
395 assert.deepEqual(rustroverLineAndColumn, {
396 command: "rustrover",
397 args: ["--line", "71", "--column", "5", "/tmp/workspace/src/open.ts"],
398 });
399
400 const webstormLineOnly = yield* resolveEditorLaunch(
401 { cwd: "/tmp/workspace/AGENTS.md:48", editor: "webstorm" },
402 "darwin",
403 );
404 assert.deepEqual(webstormLineOnly, {
405 command: "webstorm",
406 args: ["--line", "48", "/tmp/workspace/AGENTS.md"],
407 });
408 }),
409 );
410
411 it.effect("falls back to zeditor when zed is not installed", () =>
412 Effect.gen(function* () {
413 const fs = yield* FileSystem.FileSystem;
414 const path = yield* Path.Path;
415 const dir = yield* fs.makeTempDirectoryScoped({ prefix: "t3-open-test-" });
416 yield* fs.writeFileString(path.join(dir, "zeditor"), "#!/bin/sh\nexit 0\n");
417 yield* fs.chmod(path.join(dir, "zeditor"), 0o755);
418
419 const result = yield* resolveEditorLaunch({ cwd: "/tmp/workspace", editor: "zed" }, "linux", {
420 PATH: dir,
421 });
422
423 assert.deepEqual(result, {
424 command: "zeditor",
425 args: ["/tmp/workspace"],
426 });
427 }),
428 );
429
430 it.effect("falls back to the primary command when no alias is installed", () =>
431 Effect.gen(function* () {
432 const result = yield* resolveEditorLaunch({ cwd: "/tmp/workspace", editor: "zed" }, "linux", {
433 PATH: "",
434 });
435 assert.deepEqual(result, {
436 command: "zed",
437 args: ["/tmp/workspace"],
438 });
439 }),
440 );
441
442 it.effect("maps file-manager editor to OS open commands", () =>
443 Effect.gen(function* () {
444 const launch1 = yield* resolveEditorLaunch(
445 { cwd: "/tmp/workspace", editor: "file-manager" },
446 "darwin",
447 { PATH: "" },
448 );
449 assert.deepEqual(launch1, {
450 command: "open",
451 args: ["/tmp/workspace"],
452 });
453
454 const launch2 = yield* resolveEditorLaunch(
455 { cwd: "C:\\workspace", editor: "file-manager" },
456 "win32",
457 { PATH: "" },
458 );
459 assert.deepEqual(launch2, {
460 command: "explorer",
461 args: ["C:\\workspace"],
462 });
463
464 const launch3 = yield* resolveEditorLaunch(
465 { cwd: "/tmp/workspace", editor: "file-manager" },
466 "linux",
467 { PATH: "" },
468 );
469 assert.deepEqual(launch3, {
470 command: "xdg-open",
471 args: ["/tmp/workspace"],
472 });
473 }),
474 );
475});
476
477it.layer(NodeServices.layer)("launchDetached", (it) => {
478 it.effect("resolves when command can be spawned", () =>
479 Effect.gen(function* () {
480 const result = yield* launchDetached({
481 command: process.execPath,
482 args: ["-e", "process.exit(0)"],
483 }).pipe(Effect.result);
484 assertSuccess(result, undefined);
485 }),
486 );
487
488 it.effect("rejects when command does not exist", () =>
489 Effect.gen(function* () {
490 const result = yield* launchDetached({
491 command: `t3code-no-such-command-${Date.now()}`,
492 args: [],
493 }).pipe(Effect.result);
494 assert.equal(result._tag, "Failure");
495 }),
496 );
497});
498
499it.layer(NodeServices.layer)("isCommandAvailable", (it) => {
500 it.effect("resolves win32 commands with PATHEXT", () =>
501 Effect.gen(function* () {
502 const fs = yield* FileSystem.FileSystem;
503 const path = yield* Path.Path;
504 const dir = yield* fs.makeTempDirectoryScoped({ prefix: "t3-open-test-" });
505 yield* fs.writeFileString(path.join(dir, "code.CMD"), "@echo off\r\n");
506 const env = {
507 PATH: dir,
508 PATHEXT: ".COM;.EXE;.BAT;.CMD",
509 } satisfies NodeJS.ProcessEnv;
510 assert.equal(isCommandAvailable("code", { platform: "win32", env }), true);
511 }),
512 );
513
514 it("returns false when a command is not on PATH", () => {
515 const env = {
516 PATH: "",
517 PATHEXT: ".COM;.EXE;.BAT;.CMD",
518 } satisfies NodeJS.ProcessEnv;
519 assert.equal(isCommandAvailable("definitely-not-installed", { platform: "win32", env }), false);
520 });
521
522 it.effect("does not treat bare files without executable extension as available on win32", () =>
523 Effect.gen(function* () {
524 const fs = yield* FileSystem.FileSystem;
525 const path = yield* Path.Path;
526 const dir = yield* fs.makeTempDirectoryScoped({ prefix: "t3-open-test-" });
527 yield* fs.writeFileString(path.join(dir, "npm"), "echo nope\r\n");
528 const env = {
529 PATH: dir,
530 PATHEXT: ".COM;.EXE;.BAT;.CMD",
531 } satisfies NodeJS.ProcessEnv;
532 assert.equal(isCommandAvailable("npm", { platform: "win32", env }), false);
533 }),
534 );
535
536 it.effect("appends PATHEXT for commands with non-executable extensions on win32", () =>
537 Effect.gen(function* () {
538 const fs = yield* FileSystem.FileSystem;
539 const path = yield* Path.Path;
540 const dir = yield* fs.makeTempDirectoryScoped({ prefix: "t3-open-test-" });
541 yield* fs.writeFileString(path.join(dir, "my.tool.CMD"), "@echo off\r\n");
542 const env = {
543 PATH: dir,
544 PATHEXT: ".COM;.EXE;.BAT;.CMD",
545 } satisfies NodeJS.ProcessEnv;
546 assert.equal(isCommandAvailable("my.tool", { platform: "win32", env }), true);
547 }),
548 );
549
550 it.effect("uses platform-specific PATH delimiter for platform overrides", () =>
551 Effect.gen(function* () {
552 const fs = yield* FileSystem.FileSystem;
553 const path = yield* Path.Path;
554 const firstDir = yield* fs.makeTempDirectoryScoped({ prefix: "t3-open-test-" });
555 const secondDir = yield* fs.makeTempDirectoryScoped({ prefix: "t3-open-test-" });
556 yield* fs.writeFileString(path.join(firstDir, "code.CMD"), "@echo off\r\n");
557 yield* fs.writeFileString(path.join(secondDir, "code.CMD"), "MZ");
558 const env = {
559 PATH: `${firstDir};${secondDir}`,
560 PATHEXT: ".COM;.EXE;.BAT;.CMD",
561 } satisfies NodeJS.ProcessEnv;
562 assert.equal(isCommandAvailable("code", { platform: "win32", env }), true);
563 }),
564 );
565});
566
567it.layer(NodeServices.layer)("resolveAvailableEditors", (it) => {
568 it.effect("returns installed editors for command launches", () =>
569 Effect.gen(function* () {
570 const fs = yield* FileSystem.FileSystem;
571 const path = yield* Path.Path;
572 const dir = yield* fs.makeTempDirectoryScoped({ prefix: "t3-editors-" });
573
574 yield* fs.writeFileString(path.join(dir, "trae.CMD"), "@echo off\r\n");
575 yield* fs.writeFileString(path.join(dir, "kiro.CMD"), "@echo off\r\n");
576 yield* fs.writeFileString(path.join(dir, "code-insiders.CMD"), "@echo off\r\n");
577 yield* fs.writeFileString(path.join(dir, "codium.CMD"), "@echo off\r\n");
578 yield* fs.writeFileString(path.join(dir, "aqua.CMD"), "@echo off\r\n");
579 yield* fs.writeFileString(path.join(dir, "clion.CMD"), "@echo off\r\n");
580 yield* fs.writeFileString(path.join(dir, "datagrip.CMD"), "@echo off\r\n");
581 yield* fs.writeFileString(path.join(dir, "dataspell.CMD"), "@echo off\r\n");
582 yield* fs.writeFileString(path.join(dir, "goland.CMD"), "@echo off\r\n");
583 yield* fs.writeFileString(path.join(dir, "phpstorm.CMD"), "@echo off\r\n");
584 yield* fs.writeFileString(path.join(dir, "pycharm.CMD"), "@echo off\r\n");
585 yield* fs.writeFileString(path.join(dir, "rider.CMD"), "@echo off\r\n");
586 yield* fs.writeFileString(path.join(dir, "rubymine.CMD"), "@echo off\r\n");
587 yield* fs.writeFileString(path.join(dir, "rustrover.CMD"), "@echo off\r\n");
588 yield* fs.writeFileString(path.join(dir, "webstorm.CMD"), "@echo off\r\n");
589 yield* fs.writeFileString(path.join(dir, "explorer.CMD"), "MZ");
590 const editors = resolveAvailableEditors("win32", {
591 PATH: dir,
592 PATHEXT: ".COM;.EXE;.BAT;.CMD",
593 });
594 assert.deepEqual(editors, [
595 "trae",
596 "kiro",
597 "vscode-insiders",
598 "vscodium",
599 "aqua",
600 "clion",
601 "datagrip",
602 "dataspell",
603 "goland",
604 "phpstorm",
605 "pycharm",
606 "rider",
607 "rubymine",
608 "rustrover",
609 "webstorm",
610 "file-manager",
611 ]);
612 }),
613 );
614
615 it.effect("includes zed when only the zeditor command is installed", () =>
616 Effect.gen(function* () {
617 const fs = yield* FileSystem.FileSystem;
618 const path = yield* Path.Path;
619 const dir = yield* fs.makeTempDirectoryScoped({ prefix: "t3-editors-" });
620
621 yield* fs.writeFileString(path.join(dir, "zeditor"), "#!/bin/sh\nexit 0\n");
622 yield* fs.writeFileString(path.join(dir, "xdg-open"), "#!/bin/sh\nexit 0\n");
623 yield* fs.chmod(path.join(dir, "zeditor"), 0o755);
624 yield* fs.chmod(path.join(dir, "xdg-open"), 0o755);
625
626 const editors = resolveAvailableEditors("linux", {
627 PATH: dir,
628 });
629 assert.deepEqual(editors, ["zed", "file-manager"]);
630 }),
631 );
632
633 it("omits file-manager when the platform opener is unavailable", () => {
634 const editors = resolveAvailableEditors("linux", {
635 PATH: "",
636 });
637 assert.deepEqual(editors, []);
638 });
639});