chore(test): update test database
This commit is contained in:
parent
a37d4b369a
commit
42ecc91c22
@ -82,7 +82,7 @@ fillDb = do
|
|||||||
|
|
||||||
gkleen <- insert User
|
gkleen <- insert User
|
||||||
{ userIdent = "G.Kleen@campus.lmu.de"
|
{ userIdent = "G.Kleen@campus.lmu.de"
|
||||||
, userAuthentication = AuthLDAP
|
, userPasswordHash = Nothing
|
||||||
, userLastAuthentication = Just now
|
, userLastAuthentication = Just now
|
||||||
, userTokensIssuedAfter = Just now
|
, userTokensIssuedAfter = Just now
|
||||||
, userMatrikelnummer = Nothing
|
, userMatrikelnummer = Nothing
|
||||||
@ -103,10 +103,6 @@ fillDb = do
|
|||||||
, userLanguages = Just $ Languages ["en"]
|
, userLanguages = Just $ Languages ["en"]
|
||||||
, userNotificationSettings = def
|
, userNotificationSettings = def
|
||||||
, userCreated = now
|
, userCreated = now
|
||||||
, userLastLdapSynchronisation = Nothing
|
|
||||||
, userLdapPrimaryKey = Nothing
|
|
||||||
, userLastAzureSynchronisation = Nothing
|
|
||||||
, userAzurePrimaryKey = Nothing
|
|
||||||
, userCsvOptions = def { csvFormat = csvPreset # CsvPresetRFC }
|
, userCsvOptions = def { csvFormat = csvPreset # CsvPresetRFC }
|
||||||
, userSex = Just SexMale
|
, userSex = Just SexMale
|
||||||
, userBirthday = Nothing
|
, userBirthday = Nothing
|
||||||
@ -124,7 +120,7 @@ fillDb = do
|
|||||||
}
|
}
|
||||||
fhamann <- insert User
|
fhamann <- insert User
|
||||||
{ userIdent = "felix.hamann@campus.lmu.de"
|
{ userIdent = "felix.hamann@campus.lmu.de"
|
||||||
, userAuthentication = AuthLDAP
|
, userPasswordHash = Nothing
|
||||||
, userLastAuthentication = Nothing
|
, userLastAuthentication = Nothing
|
||||||
, userTokensIssuedAfter = Nothing
|
, userTokensIssuedAfter = Nothing
|
||||||
, userMatrikelnummer = Nothing
|
, userMatrikelnummer = Nothing
|
||||||
@ -145,10 +141,6 @@ fillDb = do
|
|||||||
, userLanguages = Nothing
|
, userLanguages = Nothing
|
||||||
, userNotificationSettings = def
|
, userNotificationSettings = def
|
||||||
, userCreated = now
|
, userCreated = now
|
||||||
, userLastLdapSynchronisation = Nothing
|
|
||||||
, userLdapPrimaryKey = Nothing
|
|
||||||
, userLastAzureSynchronisation = Nothing
|
|
||||||
, userAzurePrimaryKey = Nothing
|
|
||||||
, userCsvOptions = def { csvFormat = csvPreset # CsvPresetExcel }
|
, userCsvOptions = def { csvFormat = csvPreset # CsvPresetExcel }
|
||||||
, userSex = Just SexMale
|
, userSex = Just SexMale
|
||||||
, userShowSex = userDefaultShowSex
|
, userShowSex = userDefaultShowSex
|
||||||
@ -168,11 +160,10 @@ fillDb = do
|
|||||||
let pw = "123.456"
|
let pw = "123.456"
|
||||||
PWHashConf{..} <- getsYesod $ view _appAuthPWHash
|
PWHashConf{..} <- getsYesod $ view _appAuthPWHash
|
||||||
pwHash <- liftIO $ PWStore.makePasswordWith pwHashAlgorithm pw pwHashStrength
|
pwHash <- liftIO $ PWStore.makePasswordWith pwHashAlgorithm pw pwHashStrength
|
||||||
return $ AuthPWHash $ TEnc.decodeUtf8 pwHash
|
return $ TEnc.decodeUtf8 pwHash
|
||||||
jost <- insert User
|
jost <- insert User
|
||||||
{ userIdent = "jost@tcs.ifi.lmu.de"
|
{ userIdent = "jost@tcs.ifi.lmu.de"
|
||||||
-- , userAuthentication = AuthLDAP
|
, userPasswordHash = Just pwSimple
|
||||||
, userAuthentication = pwSimple
|
|
||||||
, userLastAuthentication = Nothing
|
, userLastAuthentication = Nothing
|
||||||
, userTokensIssuedAfter = Nothing
|
, userTokensIssuedAfter = Nothing
|
||||||
, userMatrikelnummer = Just "12345678"
|
, userMatrikelnummer = Just "12345678"
|
||||||
@ -193,10 +184,6 @@ fillDb = do
|
|||||||
, userLanguages = Nothing
|
, userLanguages = Nothing
|
||||||
, userNotificationSettings = def
|
, userNotificationSettings = def
|
||||||
, userCreated = now
|
, userCreated = now
|
||||||
, userLastLdapSynchronisation = Nothing
|
|
||||||
, userLdapPrimaryKey = Nothing
|
|
||||||
, userLastAzureSynchronisation = Nothing
|
|
||||||
, userAzurePrimaryKey = Nothing
|
|
||||||
, userSex = Just SexMale
|
, userSex = Just SexMale
|
||||||
, userBirthday = Just $ n_day $ 35 * (-365)
|
, userBirthday = Just $ n_day $ 35 * (-365)
|
||||||
, userCsvOptions = def
|
, userCsvOptions = def
|
||||||
@ -214,7 +201,7 @@ fillDb = do
|
|||||||
}
|
}
|
||||||
maxMuster <- insert User
|
maxMuster <- insert User
|
||||||
{ userIdent = "max@campus.lmu.de"
|
{ userIdent = "max@campus.lmu.de"
|
||||||
, userAuthentication = AuthLDAP
|
, userPasswordHash = Nothing
|
||||||
, userLastAuthentication = Just now
|
, userLastAuthentication = Just now
|
||||||
, userTokensIssuedAfter = Nothing
|
, userTokensIssuedAfter = Nothing
|
||||||
, userMatrikelnummer = Just "1299"
|
, userMatrikelnummer = Just "1299"
|
||||||
@ -235,10 +222,6 @@ fillDb = do
|
|||||||
, userLanguages = Just $ Languages ["de"]
|
, userLanguages = Just $ Languages ["de"]
|
||||||
, userNotificationSettings = def
|
, userNotificationSettings = def
|
||||||
, userCreated = now
|
, userCreated = now
|
||||||
, userLastLdapSynchronisation = Nothing
|
|
||||||
, userLdapPrimaryKey = Nothing
|
|
||||||
, userLastAzureSynchronisation = Nothing
|
|
||||||
, userAzurePrimaryKey = Nothing
|
|
||||||
, userCsvOptions = def
|
, userCsvOptions = def
|
||||||
, userSex = Just SexMale
|
, userSex = Just SexMale
|
||||||
, userBirthday = Just $ n_day $ 27 * (-365)
|
, userBirthday = Just $ n_day $ 27 * (-365)
|
||||||
@ -256,7 +239,7 @@ fillDb = do
|
|||||||
}
|
}
|
||||||
tinaTester <- insert $ User
|
tinaTester <- insert $ User
|
||||||
{ userIdent = "tester@campus.lmu.de"
|
{ userIdent = "tester@campus.lmu.de"
|
||||||
, userAuthentication = AuthNoLogin
|
, userPasswordHash = Nothing
|
||||||
, userLastAuthentication = Nothing
|
, userLastAuthentication = Nothing
|
||||||
, userTokensIssuedAfter = Nothing
|
, userTokensIssuedAfter = Nothing
|
||||||
, userMatrikelnummer = Just "999"
|
, userMatrikelnummer = Just "999"
|
||||||
@ -277,10 +260,6 @@ fillDb = do
|
|||||||
, userLanguages = Just $ Languages ["sn"]
|
, userLanguages = Just $ Languages ["sn"]
|
||||||
, userNotificationSettings = def
|
, userNotificationSettings = def
|
||||||
, userCreated = now
|
, userCreated = now
|
||||||
, userLastLdapSynchronisation = Nothing
|
|
||||||
, userLdapPrimaryKey = Nothing
|
|
||||||
, userLastAzureSynchronisation = Nothing
|
|
||||||
, userAzurePrimaryKey = Nothing
|
|
||||||
, userCsvOptions = def
|
, userCsvOptions = def
|
||||||
, userSex = Just SexNotApplicable
|
, userSex = Just SexNotApplicable
|
||||||
, userBirthday = Just $ n_day 3
|
, userBirthday = Just $ n_day 3
|
||||||
@ -298,7 +277,7 @@ fillDb = do
|
|||||||
}
|
}
|
||||||
svaupel <- insert User
|
svaupel <- insert User
|
||||||
{ userIdent = "vaupel.sarah@campus.lmu.de"
|
{ userIdent = "vaupel.sarah@campus.lmu.de"
|
||||||
, userAuthentication = AuthLDAP
|
, userPasswordHash = Nothing
|
||||||
, userLastAuthentication = Nothing
|
, userLastAuthentication = Nothing
|
||||||
, userTokensIssuedAfter = Nothing
|
, userTokensIssuedAfter = Nothing
|
||||||
, userMatrikelnummer = Nothing
|
, userMatrikelnummer = Nothing
|
||||||
@ -319,10 +298,6 @@ fillDb = do
|
|||||||
, userLanguages = Nothing
|
, userLanguages = Nothing
|
||||||
, userNotificationSettings = def
|
, userNotificationSettings = def
|
||||||
, userCreated = now
|
, userCreated = now
|
||||||
, userLastLdapSynchronisation = Nothing
|
|
||||||
, userLdapPrimaryKey = Nothing
|
|
||||||
, userLastAzureSynchronisation = Nothing
|
|
||||||
, userAzurePrimaryKey = Nothing
|
|
||||||
, userCsvOptions = def
|
, userCsvOptions = def
|
||||||
, userSex = Just SexFemale
|
, userSex = Just SexFemale
|
||||||
, userBirthday = Nothing
|
, userBirthday = Nothing
|
||||||
@ -340,7 +315,7 @@ fillDb = do
|
|||||||
}
|
}
|
||||||
sbarth <- insert User
|
sbarth <- insert User
|
||||||
{ userIdent = "Stephan.Barth@campus.lmu.de"
|
{ userIdent = "Stephan.Barth@campus.lmu.de"
|
||||||
, userAuthentication = AuthLDAP
|
, userPasswordHash = Nothing
|
||||||
, userLastAuthentication = Nothing
|
, userLastAuthentication = Nothing
|
||||||
, userTokensIssuedAfter = Nothing
|
, userTokensIssuedAfter = Nothing
|
||||||
, userMatrikelnummer = Nothing
|
, userMatrikelnummer = Nothing
|
||||||
@ -361,10 +336,6 @@ fillDb = do
|
|||||||
, userLanguages = Nothing
|
, userLanguages = Nothing
|
||||||
, userNotificationSettings = def
|
, userNotificationSettings = def
|
||||||
, userCreated = now
|
, userCreated = now
|
||||||
, userLastLdapSynchronisation = Nothing
|
|
||||||
, userLdapPrimaryKey = Nothing
|
|
||||||
, userLastAzureSynchronisation = Nothing
|
|
||||||
, userAzurePrimaryKey = Nothing
|
|
||||||
, userCsvOptions = def
|
, userCsvOptions = def
|
||||||
, userSex = Just SexMale
|
, userSex = Just SexMale
|
||||||
, userBirthday = Nothing
|
, userBirthday = Nothing
|
||||||
@ -382,7 +353,7 @@ fillDb = do
|
|||||||
}
|
}
|
||||||
_stranger1 <- insert User
|
_stranger1 <- insert User
|
||||||
{ userIdent = "AVSID:996699"
|
{ userIdent = "AVSID:996699"
|
||||||
, userAuthentication = AuthLDAP
|
, userPasswordHash = Nothing
|
||||||
, userLastAuthentication = Nothing
|
, userLastAuthentication = Nothing
|
||||||
, userTokensIssuedAfter = Nothing
|
, userTokensIssuedAfter = Nothing
|
||||||
, userMatrikelnummer = Nothing
|
, userMatrikelnummer = Nothing
|
||||||
@ -403,10 +374,6 @@ fillDb = do
|
|||||||
, userLanguages = Nothing
|
, userLanguages = Nothing
|
||||||
, userNotificationSettings = def
|
, userNotificationSettings = def
|
||||||
, userCreated = now
|
, userCreated = now
|
||||||
, userLastLdapSynchronisation = Nothing
|
|
||||||
, userLdapPrimaryKey = Nothing
|
|
||||||
, userLastAzureSynchronisation = Nothing
|
|
||||||
, userAzurePrimaryKey = Nothing
|
|
||||||
, userCsvOptions = def
|
, userCsvOptions = def
|
||||||
, userSex = Just SexMale
|
, userSex = Just SexMale
|
||||||
, userBirthday = Nothing
|
, userBirthday = Nothing
|
||||||
@ -424,7 +391,7 @@ fillDb = do
|
|||||||
}
|
}
|
||||||
_stranger2 <- insert User
|
_stranger2 <- insert User
|
||||||
{ userIdent = "AVSID:669966"
|
{ userIdent = "AVSID:669966"
|
||||||
, userAuthentication = AuthLDAP
|
, userPasswordHash = Nothing
|
||||||
, userLastAuthentication = Nothing
|
, userLastAuthentication = Nothing
|
||||||
, userTokensIssuedAfter = Nothing
|
, userTokensIssuedAfter = Nothing
|
||||||
, userMatrikelnummer = Nothing
|
, userMatrikelnummer = Nothing
|
||||||
@ -445,10 +412,6 @@ fillDb = do
|
|||||||
, userLanguages = Nothing
|
, userLanguages = Nothing
|
||||||
, userNotificationSettings = def
|
, userNotificationSettings = def
|
||||||
, userCreated = now
|
, userCreated = now
|
||||||
, userLastLdapSynchronisation = Nothing
|
|
||||||
, userLdapPrimaryKey = Nothing
|
|
||||||
, userLastAzureSynchronisation = Nothing
|
|
||||||
, userAzurePrimaryKey = Nothing
|
|
||||||
, userCsvOptions = def
|
, userCsvOptions = def
|
||||||
, userSex = Just SexMale
|
, userSex = Just SexMale
|
||||||
, userBirthday = Nothing
|
, userBirthday = Nothing
|
||||||
@ -466,7 +429,7 @@ fillDb = do
|
|||||||
}
|
}
|
||||||
_stranger3 <- insert User
|
_stranger3 <- insert User
|
||||||
{ userIdent = "AVSID:6969"
|
{ userIdent = "AVSID:6969"
|
||||||
, userAuthentication = AuthLDAP
|
, userPasswordHash = Nothing
|
||||||
, userLastAuthentication = Nothing
|
, userLastAuthentication = Nothing
|
||||||
, userTokensIssuedAfter = Nothing
|
, userTokensIssuedAfter = Nothing
|
||||||
, userMatrikelnummer = Nothing
|
, userMatrikelnummer = Nothing
|
||||||
@ -487,10 +450,6 @@ fillDb = do
|
|||||||
, userLanguages = Nothing
|
, userLanguages = Nothing
|
||||||
, userNotificationSettings = def
|
, userNotificationSettings = def
|
||||||
, userCreated = now
|
, userCreated = now
|
||||||
, userLastLdapSynchronisation = Nothing
|
|
||||||
, userLdapPrimaryKey = Nothing
|
|
||||||
, userLastAzureSynchronisation = Nothing
|
|
||||||
, userAzurePrimaryKey = Nothing
|
|
||||||
, userCsvOptions = def
|
, userCsvOptions = def
|
||||||
, userSex = Just SexMale
|
, userSex = Just SexMale
|
||||||
, userBirthday = Nothing
|
, userBirthday = Nothing
|
||||||
@ -546,7 +505,7 @@ fillDb = do
|
|||||||
middlenames = [ Nothing, Just "Jamesson", Just "Theresa", Just "Ally", Just "Tiberius", Just "Maria" ]
|
middlenames = [ Nothing, Just "Jamesson", Just "Theresa", Just "Ally", Just "Tiberius", Just "Maria" ]
|
||||||
manyUser (firstName, middleName, userSurname) userMatrikelnummer' = User
|
manyUser (firstName, middleName, userSurname) userMatrikelnummer' = User
|
||||||
{ userIdent
|
{ userIdent
|
||||||
, userAuthentication = AuthLDAP
|
, userPasswordHash = Nothing
|
||||||
, userLastAuthentication = Nothing
|
, userLastAuthentication = Nothing
|
||||||
, userTokensIssuedAfter = Nothing
|
, userTokensIssuedAfter = Nothing
|
||||||
, userMatrikelnummer = Just userMatrikelnummer'
|
, userMatrikelnummer = Just userMatrikelnummer'
|
||||||
@ -569,10 +528,6 @@ fillDb = do
|
|||||||
, userLanguages = Nothing
|
, userLanguages = Nothing
|
||||||
, userNotificationSettings = def
|
, userNotificationSettings = def
|
||||||
, userCreated = now
|
, userCreated = now
|
||||||
, userLastLdapSynchronisation = Nothing
|
|
||||||
, userLdapPrimaryKey = Nothing
|
|
||||||
, userLastAzureSynchronisation = Nothing
|
|
||||||
, userAzurePrimaryKey = Nothing
|
|
||||||
, userCsvOptions = def
|
, userCsvOptions = def
|
||||||
, userSex = Nothing
|
, userSex = Nothing
|
||||||
, userBirthday = Nothing
|
, userBirthday = Nothing
|
||||||
|
|||||||
Reference in New Issue
Block a user