integration-0.1.0
Safe HaskellSafe-Inferred
LanguageGHC2021

Test.LegalHold

Synopsis

Documentation

testLHMessageExchange :: HasCallStack => TaggedBool "clients1New" -> TaggedBool "clients2New" -> App () Source #

data TestClaimKeys Source #

Instances

Instances details
Generic TestClaimKeys Source # 
Instance details

Defined in Test.LegalHold

Associated Types

type Rep TestClaimKeys :: Type -> Type #

Show TestClaimKeys Source # 
Instance details

Defined in Test.LegalHold

type Rep TestClaimKeys Source # 
Instance details

Defined in Test.LegalHold

type Rep TestClaimKeys = D1 ('MetaData "TestClaimKeys" "Test.LegalHold" "integration-0.1.0-HxuAbotgcOkA6o44Dy58kl" 'False) (C1 ('MetaCons "TCKConsentMissing" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "TCKConsentAndNewClients" 'PrefixI 'False) (U1 :: Type -> Type))

data LHApprovedOrPending Source #

Constructors

LHApproved 
LHPending 

Instances

Instances details
Generic LHApprovedOrPending Source # 
Instance details

Defined in Test.LegalHold

Associated Types

type Rep LHApprovedOrPending :: Type -> Type #

Show LHApprovedOrPending Source # 
Instance details

Defined in Test.LegalHold

type Rep LHApprovedOrPending Source # 
Instance details

Defined in Test.LegalHold

type Rep LHApprovedOrPending = D1 ('MetaData "LHApprovedOrPending" "Test.LegalHold" "integration-0.1.0-HxuAbotgcOkA6o44Dy58kl" 'False) (C1 ('MetaCons "LHApproved" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "LHPending" 'PrefixI 'False) (U1 :: Type -> Type))

testLHClaimKeys :: LHApprovedOrPending -> TestClaimKeys -> App () Source #

Cannot fetch prekeys of LH users if requester has not given consent or has old clients.

checkChan :: HasCallStack => Chan t -> (t -> App (Maybe a)) -> App a Source #

pops a channel until it finds an event that returns a Just upon running the matcher function

checkChanVal :: HasCallStack => Chan (t, LazyByteString) -> (Value -> MaybeT App a) -> App a Source #

like checkChan but throws away the request and decodes the body

setTimeoutTo :: Int -> Env -> Env Source #

this sets the timeout to a higher number; we need this because the SQS queue on the brig is super slow and that's why client.remove events arrive really late

FUTUREWORK(mangoiv): improve the speed of internal event queuing

data GroupConvAdmin Source #

Instances

Instances details
Generic GroupConvAdmin Source # 
Instance details

Defined in Test.LegalHold

Associated Types

type Rep GroupConvAdmin :: Type -> Type #

Show GroupConvAdmin Source # 
Instance details

Defined in Test.LegalHold

type Rep GroupConvAdmin Source # 
Instance details

Defined in Test.LegalHold

type Rep GroupConvAdmin = D1 ('MetaData "GroupConvAdmin" "Test.LegalHold" "integration-0.1.0-HxuAbotgcOkA6o44Dy58kl" 'False) (C1 ('MetaCons "LegalholderIsAdmin" 'PrefixI 'False) (U1 :: Type -> Type) :+: (C1 ('MetaCons "PeerIsAdmin" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "BothAreAdmins" 'PrefixI 'False) (U1 :: Type -> Type)))

testLHNoConsentRemoveFromGroup :: LHApprovedOrPending -> GroupConvAdmin -> App () Source #

If a member of an existing conversation is assigned a LH device, users are removed from the conversation until policy conflicts are resolved.

As to who gets to stay: - admins will stay over members - local members will stay over remote members.

testBlockCreateMLSConvForLHUsers :: HasCallStack => App () Source #

scenario 2.2: charlie is put under legalhold but creates an MLS Group himself since he doesn't need to claim his own keypackage to do so, this would succeed we need to check upon group creation if the user is under legalhold and reject the operation if they are