Skip to content

Commit d8cb802

Browse files
authored
Merge pull request #122 from unisoncomputing/notifications-playwright
Notifications playwright
2 parents 44ac53e + 550ebc4 commit d8cb802

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

tests/e2e/TestHelpers/Api.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -611,7 +611,7 @@ async function getNotificationsHub(
611611
};
612612

613613
return get(page, {
614-
url: `/users/${handle.replace("@", "")}/notifications/hub?status=read%2Cunread&limit=12`,
614+
url: `/users/${handle.replace("@", "")}/notifications/hub?status=read%2Cunread&limit=24`,
615615
status: 200,
616616
data: data,
617617
});

tests/e2e/TestHelpers/Data.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -675,6 +675,10 @@ function notificationStatus(): NotificationStatus {
675675
return faker.helpers.arrayElement(["unread", "read", "archived"]);
676676
}
677677

678+
function notificationStatusWithoutArchived(): NotificationStatus {
679+
return faker.helpers.arrayElement(["unread", "read"]);
680+
}
681+
678682
type Notification = {
679683
id: string;
680684
event: NotificationEvent;
@@ -688,7 +692,7 @@ function notification(notif?: {
688692
return {
689693
event: notificationEvent(notif?.kind),
690694
id: faker.string.uuid(),
691-
status: notif?.status || notificationStatus(),
695+
status: notif?.status || notificationStatusWithoutArchived(),
692696
};
693697
}
694698

0 commit comments

Comments
 (0)