mirror of
https://github.com/maputnik/editor.git
synced 2025-12-06 06:10:00 +00:00
Co-authored-by: shelly_goldblit <shelly_goldblit@dell.com> Co-authored-by: HarelM <harel.mazor@gmail.com>
27 lines
828 B
TypeScript
27 lines
828 B
TypeScript
import { MaputnikDriver } from "./maputnik-driver";
|
|
|
|
describe("map", () => {
|
|
let { beforeAndAfter, get, when, then } = new MaputnikDriver();
|
|
beforeAndAfter();
|
|
describe("zoom level", () => {
|
|
it("via url", () => {
|
|
let zoomLevel = 12.37;
|
|
when.setStyle("geojson", zoomLevel);
|
|
then(get.elementByTestId("maplibre:ctrl-zoom")).shouldBeVisible();
|
|
then(get.elementByTestId("maplibre:ctrl-zoom")).shouldContainText(
|
|
"Zoom: " + zoomLevel
|
|
);
|
|
});
|
|
|
|
it("via map controls", () => {
|
|
let zoomLevel = 12.37;
|
|
when.setStyle("geojson", zoomLevel);
|
|
then(get.elementByTestId("maplibre:ctrl-zoom")).shouldBeVisible();
|
|
when.clickZoomIn();
|
|
then(get.elementByTestId("maplibre:ctrl-zoom")).shouldContainText(
|
|
"Zoom: " + (zoomLevel + 1)
|
|
);
|
|
});
|
|
});
|
|
});
|