integration-0.1.0
Safe HaskellNone
LanguageGHC2021

Test.Meetings

Synopsis

Documentation

getMeetingIdAndDomain :: HasCallStack => Value -> App (String, String) Source #

Helper to extract meetingId and domain from a meeting JSON object

assertConversationMatchesLegacy :: HasCallStack => Value -> App () Source #

On create/update responses, the full conversation object is returned alongside the legacy qualified_conversation field. This asserts that both refer to the same conversation.

assertMeetingNotif :: (HasCallStack, MakesValue notif, MakesValue qid) => notif -> qid -> App () Source #

Assert a meeting lifecycle notification carries the meeting's qualified id flat at payload.0.qualified_id and has NO "data" wrapper (proves the no-nesting contract).

defaultMeetingJson :: String -> UTCTime -> UTCTime -> [String] -> Value Source #

Helper to create a default new meeting JSON object

defaultMeetingJsonLegacy :: String -> UTCTime -> UTCTime -> [String] -> Value Source #

Legacy (V15/V16) meeting JSON: carries end_time and no tzid (V17 adds tzid). Used to exercise the legacy endpoints in interop tests.

testMeetingsReadsWhenDisabled :: HasCallStack => App () Source #

Read endpoints (GET meetingslist, GET meetings{domain}/{id}) treat a team with the meetings feature disabled as "no meetings" (list -> 200 [], get -> 404 meeting-not-found) instead of 403 invalid-op, while write endpoints (POST /meetings) keep the hard gate and still return 403 invalid-op. See WPB-27329.

testMeetingUpdateTzid :: HasCallStack => App () Source #

WPB-28272: PUT meetings{domain}/{id} accepts an optional tzid and updates the stored time zone; omitting it (as legacy clients do) keeps the stored value; an invalid tzid is rejected at decode time.

testMeetingLifecycleEventsDeliveredToMembers :: HasCallStack => App () Source #

WPB-27907: meeting lifecycle events are delivered to all conversation members; only the originating client connection is excluded (no redundant echo), while the initiator's other client connections and all other members receive them. This test covers the non-initiator member path: a member who joined the meeting conversation after creation receives 'meeting.update' and 'meeting.delete'. The originating-client-connection exclusion is covered in testMeetingOriginatingConnectionExcluded; the multi-member recipient set is covered at the unit level in Wire.MeetingsSubsystem.InterpreterSpec.

waitForCleanupJob :: (HasCallStack, MakesValue domain) => domain -> App () Source #

testMeetingInteropNewToLegacy :: HasCallStack => App () Source #

A meeting created via the V19 shape (end_time + tzid + type) is visible to legacy clients (< V17) with an end_time; V19 reads carry end_time too.

testMeetingInteropLegacyToNew :: HasCallStack => App () Source #

A meeting created via the legacy shape (end_time) is visible to V19 clients with end_time and the injected default tzid (Europe/Berlin).

testMeetingType :: HasCallStack => App () Source #

WPB-28985: the V19 meeting object exposes a type field (immediate or scheduled); required on create, optional on update.

testMeetingLink :: HasCallStack => App () Source #

WPB-28987: the V19 meeting object exposes an optional link join link whose final path segment is the meeting's UUID; it is present only when the meeting has a live join code. Legacy endpoint shapes are unchanged.

testMeetingLinkMultiIngress :: HasCallStack => App () Source #

WPB-28987: in multi-ingress mode a meeting created by a user whose domain has no configured join-link URI carries no link field (the old fallback would have fabricated one). Holds regardless of code-storage mode.

testMeetingInteropV18ToV19 :: HasCallStack => App () Source #

A meeting created via the V18 shape (no type) is readable via V19 and carries the stored default type scheduled.