mirror of
https://github.com/MichMich/MagicMirror.git
synced 2025-06-27 11:50:00 +00:00
parent
319a921f75
commit
a7af76b619
@ -45,6 +45,7 @@ _This release is scheduled to be released on 2024-01-01._
|
|||||||
- Fix updatanotification (update_helper.js): catch error if reponse is not an JSON format (check PM2)
|
- Fix updatanotification (update_helper.js): catch error if reponse is not an JSON format (check PM2)
|
||||||
- Fix missing typeof in calendar module
|
- Fix missing typeof in calendar module
|
||||||
- Fix style issues after prettier update
|
- Fix style issues after prettier update
|
||||||
|
- Fix calendar test (#3291) by moving "Exdate check" from e2e to electron to run on a Thursday
|
||||||
|
|
||||||
## [2.25.0] - 2023-10-01
|
## [2.25.0] - 2023-10-01
|
||||||
|
|
||||||
|
@ -87,17 +87,6 @@ describe("Calendar module", () => {
|
|||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
describe("exdate check", () => {
|
|
||||||
beforeAll(async () => {
|
|
||||||
await helpers.startApplication("tests/configs/modules/calendar/exdate.js");
|
|
||||||
await helpers.getDocument();
|
|
||||||
});
|
|
||||||
|
|
||||||
it("should show the recurring event 51 times (excluded once) in a 364-day (inclusive) period", async () => {
|
|
||||||
await expect(testElementLength(".calendar .event", 51)).resolves.toBe(true);
|
|
||||||
});
|
|
||||||
});
|
|
||||||
|
|
||||||
describe("Events from multiple calendars", () => {
|
describe("Events from multiple calendars", () => {
|
||||||
beforeAll(async () => {
|
beforeAll(async () => {
|
||||||
await helpers.startApplication("tests/configs/modules/calendar/show-duplicates-in-calendar.js");
|
await helpers.startApplication("tests/configs/modules/calendar/show-duplicates-in-calendar.js");
|
||||||
|
@ -7,7 +7,7 @@ describe("Calendar module", () => {
|
|||||||
* @returns {boolean} result
|
* @returns {boolean} result
|
||||||
*/
|
*/
|
||||||
const doTest = async (cssClass) => {
|
const doTest = async (cssClass) => {
|
||||||
let elem = await helpers.getElement(`.calendar .module-content .event${cssClass}`);
|
const elem = await helpers.getElement(`.calendar .module-content .event${cssClass}`);
|
||||||
await expect(elem.isVisible()).resolves.toBe(true);
|
await expect(elem.isVisible()).resolves.toBe(true);
|
||||||
return true;
|
return true;
|
||||||
};
|
};
|
||||||
@ -42,4 +42,18 @@ describe("Calendar module", () => {
|
|||||||
await expect(doTest(".dayAfterTomorrow")).resolves.toBe(true);
|
await expect(doTest(".dayAfterTomorrow")).resolves.toBe(true);
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
describe("Exdate check", () => {
|
||||||
|
it("should show the recurring event 51 times (excluded once) in a 364-day (inclusive) period", async () => {
|
||||||
|
// test must run on a Thursday
|
||||||
|
await helpers.startApplication("tests/configs/modules/calendar/exdate.js", "14 Dec 2023 12:30:00 GMT");
|
||||||
|
expect(global.page).not.toBeNull();
|
||||||
|
const loc = await global.page.locator(".calendar .event");
|
||||||
|
const elem = loc.first();
|
||||||
|
await elem.waitFor();
|
||||||
|
expect(elem).not.toBeNull();
|
||||||
|
const cnt = await loc.count();
|
||||||
|
expect(cnt).toBe(51);
|
||||||
|
});
|
||||||
|
});
|
||||||
});
|
});
|
||||||
|
Loading…
x
Reference in New Issue
Block a user