mirror of
https://github.com/maputnik/editor.git
synced 2026-08-24 14:07:33 +00:00
use driver
This commit is contained in:
@@ -2,7 +2,7 @@ import { MaputnikDriver } from "./maputnik-driver";
|
|||||||
import tokens from "../../src/config/tokens.json" with {type: "json"};
|
import tokens from "../../src/config/tokens.json" with {type: "json"};
|
||||||
|
|
||||||
describe("modals", () => {
|
describe("modals", () => {
|
||||||
const { beforeAndAfter, when, get, then } = new MaputnikDriver();
|
const { beforeAndAfter, when, get, given, then } = new MaputnikDriver();
|
||||||
beforeAndAfter();
|
beforeAndAfter();
|
||||||
|
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
@@ -239,7 +239,7 @@ describe("modals", () => {
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
it.only("inlcude API key when change renderer", () => {
|
it("inlcude API key when change renderer", () => {
|
||||||
|
|
||||||
when.click("modal:settings.close-modal")
|
when.click("modal:settings.close-modal")
|
||||||
when.click("nav:open");
|
when.click("nav:open");
|
||||||
@@ -258,8 +258,8 @@ describe("modals", () => {
|
|||||||
"ol"
|
"ol"
|
||||||
);
|
);
|
||||||
|
|
||||||
cy.intercept("GET", "https://api.maptiler.com/tiles/v3-openmaptiles/tiles.json?key=*").as("tileRequest");
|
given.intercept("https://api.maptiler.com/tiles/v3-openmaptiles/tiles.json?key=*", "tileRequest", "GET");
|
||||||
|
|
||||||
when.select("modal:settings.maputnik:renderer", "mlgljs");
|
when.select("modal:settings.maputnik:renderer", "mlgljs");
|
||||||
then(get.inputValue("modal:settings.maputnik:renderer")).shouldEqual(
|
then(get.inputValue("modal:settings.maputnik:renderer")).shouldEqual(
|
||||||
"mlgljs"
|
"mlgljs"
|
||||||
|
|||||||
Reference in New Issue
Block a user