Move ShowDataLayer-implementation to a separate class for nodejs compatibility

This commit is contained in:
Pieter Vander Vennet 2022-04-30 00:41:33 +02:00
parent 7a76109d61
commit f4a965eacf
5 changed files with 364 additions and 334 deletions

View file

@ -6,6 +6,8 @@ import LayoutConfig from "../../../../Models/ThemeConfig/LayoutConfig";
import State from "../../../../State";
import {BBox} from "../../../../Logic/BBox";
import ReplaceGeometryAction from "../../../../Logic/Osm/Actions/ReplaceGeometryAction";
import ShowDataLayerImplementation from "../../../../UI/ShowDataLayer/ShowDataLayerImplementation";
import ShowDataLayer from "../../../../UI/ShowDataLayer/ShowDataLayer";
describe("ReplaceGeometryAction", () => {
@ -874,7 +876,7 @@ it("should move nodes accordingly", async () => {
const layout = new LayoutConfig(<any>grbStripped)
ShowDataLayer.actualContstructor = (_) => undefined;
const state = new State(layout)
State.state = state;