diff --git a/client/src/components/ActivityBar/ActivityBar.test.js b/client/src/components/ActivityBar/ActivityBar.test.js index 1fbab6c98cad..8d1b7fc8bfb4 100644 --- a/client/src/components/ActivityBar/ActivityBar.test.js +++ b/client/src/components/ActivityBar/ActivityBar.test.js @@ -45,7 +45,7 @@ describe("ActivityBar", () => { beforeEach(async () => { const pinia = createTestingPinia({ stubActions: false }); - activityStore = useActivityStore(); + activityStore = useActivityStore("default"); eventStore = useEventStore(); wrapper = shallowMount(mountTarget, { localVue, diff --git a/client/src/components/ActivityBar/ActivityBar.vue b/client/src/components/ActivityBar/ActivityBar.vue index cde4d7b190ad..5371d14f84fe 100644 --- a/client/src/components/ActivityBar/ActivityBar.vue +++ b/client/src/components/ActivityBar/ActivityBar.vue @@ -1,11 +1,13 @@ diff --git a/client/src/components/ActivityBar/ActivityItem.test.js b/client/src/components/ActivityBar/ActivityItem.test.js index d4486230dda9..c1177158befa 100644 --- a/client/src/components/ActivityBar/ActivityItem.test.js +++ b/client/src/components/ActivityBar/ActivityItem.test.js @@ -1,3 +1,4 @@ +import { createTestingPinia } from "@pinia/testing"; import { mount } from "@vue/test-utils"; import { getLocalVue } from "tests/jest/helpers"; @@ -12,6 +13,7 @@ describe("ActivityItem", () => { wrapper = mount(mountTarget, { propsData: { id: "activity-test-id", + activityBarId: "activity-bar-test-id", icon: "activity-test-icon", indicator: 0, progressPercentage: 0, @@ -20,6 +22,7 @@ describe("ActivityItem", () => { to: null, tooltip: "activity-test-tooltip", }, + pinia: createTestingPinia(), localVue, stubs: { FontAwesomeIcon: true, @@ -28,8 +31,7 @@ describe("ActivityItem", () => { }); it("rendering", async () => { - const reference = wrapper.find("[id='activity-test-id']"); - expect(reference.attributes().id).toBe("activity-test-id"); + const reference = wrapper.find(".activity-item"); expect(reference.text()).toBe("activity-test-title"); expect(reference.find("[icon='activity-test-icon']").exists()).toBeTruthy(); expect(reference.find(".progress").exists()).toBeFalsy(); @@ -45,7 +47,7 @@ describe("ActivityItem", () => { }); it("rendering indicator", async () => { - const reference = wrapper.find("[id='activity-test-id']"); + const reference = wrapper.find(".activity-item"); const indicatorSelector = "[data-description='activity indicator']"; const noindicator = reference.find(indicatorSelector); expect(noindicator.exists()).toBeFalsy(); diff --git a/client/src/components/ActivityBar/ActivityItem.vue b/client/src/components/ActivityBar/ActivityItem.vue index 0586a1657f99..fa7e67d5e8c0 100644 --- a/client/src/components/ActivityBar/ActivityItem.vue +++ b/client/src/components/ActivityBar/ActivityItem.vue @@ -1,7 +1,14 @@