From ca20f41d0ef5cd14974837d8b7fff40a6daf66bb Mon Sep 17 00:00:00 2001 From: Nick O'Leary Date: Sun, 3 Jul 2022 20:37:55 +0100 Subject: [PATCH] Update theme tests to ensure monaco is loaded --- test/unit/@node-red/editor-api/lib/editor/theme_spec.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/test/unit/@node-red/editor-api/lib/editor/theme_spec.js b/test/unit/@node-red/editor-api/lib/editor/theme_spec.js index 900be126f..fd1b42d61 100644 --- a/test/unit/@node-red/editor-api/lib/editor/theme_spec.js +++ b/test/unit/@node-red/editor-api/lib/editor/theme_spec.js @@ -51,7 +51,7 @@ describe("api/editor/theme", function () { context.should.have.a.property("asset"); context.asset.should.have.a.property("red", "red/red.min.js"); context.asset.should.have.a.property("main", "red/main.min.js"); - context.asset.should.have.a.property("vendorMonaco", ""); + context.asset.should.have.a.property("vendorMonaco", "vendor/monaco/monaco-bootstrap.js"); should.not.exist(theme.settings()); }); @@ -69,16 +69,16 @@ describe("api/editor/theme", function () { } }); - it("Adds monaco bootstrap when enabled", async function () { + it("Does not add monaco bootstrap when ace selected", async function () { theme.init({ editorTheme: { codeEditor: { - lib: 'monaco' + lib: 'ace' } } }); var context = await theme.context(); - context.asset.should.have.a.property("vendorMonaco", "vendor/monaco/monaco-bootstrap.js"); + context.asset.should.have.a.property("vendorMonaco", ""); }); it("picks up custom theme", async function () {