mirror of
https://github.com/Quad4-Software/MeshChatX.git
synced 2026-08-18 09:49:09 -04:00
fix: update MapDrawing tests to correctly reflect button existence and interaction for bearing mode
This commit is contained in:
parent
8265ae126f
commit
82f6d75b65
2 changed files with 6 additions and 2 deletions
BIN
meshchatx.rsm
BIN
meshchatx.rsm
Binary file not shown.
|
|
@ -376,7 +376,7 @@ describe("MapPage.vue - Drawing and Measurement Tools", () => {
|
|||
const wrapper = mountMapPage();
|
||||
await wrapper.vm.$nextTick();
|
||||
expect(wrapper.find('button[title="map.tool_bearing"]').exists()).toBe(true);
|
||||
expect(wrapper.find('button[title="map.tool_bearing_from_here"]').exists()).toBe(true);
|
||||
expect(wrapper.find('button[title="map.tool_bearing_from_here"]').exists()).toBe(false);
|
||||
});
|
||||
|
||||
it("toggles bearing mode", async () => {
|
||||
|
|
@ -419,7 +419,11 @@ describe("MapPage.vue - Drawing and Measurement Tools", () => {
|
|||
await wrapper.vm.$nextTick();
|
||||
await new Promise((resolve) => setTimeout(resolve, 50));
|
||||
await wrapper.vm.$nextTick();
|
||||
await wrapper.find('button[title="map.tool_bearing_from_here"]').trigger("click");
|
||||
await wrapper.find('button[title="map.tool_bearing"]').trigger("click");
|
||||
await wrapper.vm.$nextTick();
|
||||
const fromHere = wrapper.findComponent({ name: "MapBearingInstructions" }).find("button");
|
||||
expect(fromHere.exists()).toBe(true);
|
||||
await fromHere.trigger("click");
|
||||
await flushPromises();
|
||||
await wrapper.vm.$nextTick();
|
||||
expect(wrapper.vm.isBearingMode).toBe(true);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue