Skip to content

Commit

Permalink
chore: Fix build errors
Browse files Browse the repository at this point in the history
  • Loading branch information
clepski committed Dec 5, 2024
1 parent 78a2003 commit 4290ac8
Show file tree
Hide file tree
Showing 4 changed files with 19 additions and 12 deletions.
8 changes: 7 additions & 1 deletion packages/compas-open-scd/src/open-scd.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,13 @@ import './addons/CompasSettings.js';

import '@openscd/open-scd/src/addons/Waiter.js';
import { initializeNsdoc, Nsdoc } from '@openscd/open-scd/src/foundation/nsdoc.js';
import { AddExternalPluginEvent, InstalledOfficialPlugin, SetPluginsEvent, withoutContent, Plugin, MenuPosition, PluginKind, menuOrder, pluginTag, staticTagHtml } from '@openscd/open-scd/src/open-scd.js';
import { AddExternalPluginEvent, SetPluginsEvent, withoutContent, menuOrder, pluginTag, staticTagHtml } from '@openscd/open-scd/src/open-scd.js';
import {
InstalledOfficialPlugin,
Plugin,
MenuPosition,
PluginKind,
} from '@openscd/open-scd/src/plugin.js';
import { officialPlugins } from '../public/js/plugins.js';
import type {
PluginSet,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
import { expect, fixtureSync, html, waitUntil } from '@open-wc/testing';
import sinon, { SinonSpy, spy, SinonStub } from 'sinon';

import { Editing } from '@openscd/open-scd/src/Editing.js';
import { Wizarding } from '@openscd/open-scd/src/Wizarding.js';
import '@openscd/open-scd/test/mock-editor-logger.js';
import { MockEditorLogger } from '@openscd/open-scd/test/mock-editor-logger.js';

import {
BASIC_VERSIONS_LIST_RESPONSE,
Expand All @@ -18,7 +19,7 @@ describe('compas-versions-plugin', () => {

customElements.define(
'compas-versions-plugin',
Wizarding(Editing(CompasVersionsPlugin))
Wizarding(CompasVersionsPlugin)
);
let doc: Document;
let element: CompasVersionsPlugin;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
import { expect, fixture, html } from '@open-wc/testing';

import '@openscd/open-scd/test/unit/mock-editor.js';
import { MockEditor } from '@openscd/open-scd/test/unit/mock-editor.js';
import '@openscd/open-scd/test/mock-editor-logger.js';
import { MockEditorLogger } from '@openscd/open-scd/test/mock-editor-logger.js';
import '../../../src/compas-editors/autogen-substation.js';
import CompasAutogenerateSubstation from '../../../src/compas-editors/autogen-substation.js';

describe('autogen-substation-integration', () => {
if (customElements.get('') === undefined)
customElements.define('autogen-substation', CompasAutogenerateSubstation);

let parent: MockEditor;
let parent: MockEditorLogger;
let element: CompasAutogenerateSubstation;
let validSCL: XMLDocument;

before(async () => {
parent = await fixture(html`
<mock-editor><autogen-substation></autogen-substation></mock-editor>
<mock-editor-logger><autogen-substation></autogen-substation></mock-editor-logger>
`);

validSCL = await fetch(
Expand Down
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
import { expect, fixture, html } from '@open-wc/testing';
import { stub } from 'sinon';

import '@openscd/open-scd/test/unit/mock-editor.js';
import { SitipeBay } from '../../../src/compas-editors/sitipe/sitipe-bay.js';
import { MockEditor } from '@openscd/open-scd/test/unit/mock-editor.js';
import '@openscd/open-scd/test/mock-editor-logger.js';
import { MockEditorLogger } from '@openscd/open-scd/test/mock-editor-logger.js';

describe('sitipe-bay-integration', () => {
if (customElements.get('sitipe-bay') === undefined) {
customElements.define('sitipe-bay', SitipeBay);
}

let element: SitipeBay;
let parent: MockEditor;
let parent: MockEditorLogger;
let validSCL: XMLDocument;

let bayTypicals: unknown[];
Expand Down Expand Up @@ -56,13 +56,13 @@ describe('sitipe-bay-integration', () => {
];

parent = await fixture(
html`<mock-editor .doc=${validSCL}
html`<mock-editor-logger .doc=${validSCL}
><sitipe-bay
.doc=${validSCL}
.bay=${bay}
.bayTypicals=${bayTypicals}
></sitipe-bay
></mock-editor>`
></mock-editor-logger>`
);

element = parent.querySelector('sitipe-bay')!;
Expand Down

0 comments on commit 4290ac8

Please sign in to comment.