persistent-test-2.0.3.1: Tests for Persistent
MigrationTest
data Target Source #
Constructors
Fields
Defined in MigrationTest
Methods
(==) :: Target -> Target -> Bool #
(/=) :: Target -> Target -> Bool #
showsPrec :: Int -> Target -> ShowS #
show :: Target -> String #
showList :: [Target] -> ShowS #
sqlType :: Proxy Target -> SqlType #
onlyUniqueP :: Target -> Unique Target #
requireUniquesP :: Target -> NonEmpty (Unique Target) #
Associated Types
type PersistEntityBackend Target :: Type #
data Key Target :: Type #
data EntityField Target a :: Type #
data Unique Target :: Type #
keyToValues :: Key Target -> [PersistValue] #
keyFromValues :: [PersistValue] -> Either Text (Key Target) #
persistIdField :: EntityField Target (Key Target) #
entityDef :: Monad m => m Target -> EntityDef #
persistFieldDef :: EntityField Target typ -> FieldDef #
toPersistFields :: Target -> [SomePersistField] #
fromPersistValues :: [PersistValue] -> Either Text Target #
persistUniqueKeys :: Target -> [Unique Target] #
persistUniqueToFieldNames :: Unique Target -> [(HaskellName, DBName)] #
persistUniqueToValues :: Unique Target -> [PersistValue] #
fieldLens :: EntityField Target field -> forall (f :: Type -> Type). Functor f => (field -> f field) -> Entity Target -> f (Entity Target) #
toPersistValue :: Target -> PersistValue #
fromPersistValue :: PersistValue -> Either Text Target #
deleteCascade :: MonadIO m => Key Target -> ReaderT backend m () #
toBackendKey :: Key Target -> BackendKey SqlBackend #
fromBackendKey :: BackendKey SqlBackend -> Key Target #
(==) :: Key Target -> Key Target -> Bool #
(/=) :: Key Target -> Key Target -> Bool #
compare :: Key Target -> Key Target -> Ordering #
(<) :: Key Target -> Key Target -> Bool #
(<=) :: Key Target -> Key Target -> Bool #
(>) :: Key Target -> Key Target -> Bool #
(>=) :: Key Target -> Key Target -> Bool #
max :: Key Target -> Key Target -> Key Target #
min :: Key Target -> Key Target -> Key Target #
readsPrec :: Int -> ReadS (Key Target) #
readList :: ReadS [Key Target] #
readPrec :: ReadPrec (Key Target) #
readListPrec :: ReadPrec [Key Target] #
showsPrec :: Int -> Unique Target -> ShowS #
show :: Unique Target -> String #
showList :: [Unique Target] -> ShowS #
showsPrec :: Int -> Key Target -> ShowS #
show :: Key Target -> String #
showList :: [Key Target] -> ShowS #
toJSON :: Key Target -> Value #
toEncoding :: Key Target -> Encoding #
toJSONList :: [Key Target] -> Value #
toEncodingList :: [Key Target] -> Encoding #
parseJSON :: Value -> Parser (Key Target) #
parseJSONList :: Value -> Parser [Key Target] #
toUrlPiece :: Key Target -> Text #
toEncodedUrlPiece :: Key Target -> Builder #
toHeader :: Key Target -> ByteString #
toQueryParam :: Key Target -> Text #
parseUrlPiece :: Text -> Either Text (Key Target) #
parseHeader :: ByteString -> Either Text (Key Target) #
parseQueryParam :: Text -> Either Text (Key Target) #
fromPathPiece :: Text -> Maybe (Key Target) #
toPathPiece :: Key Target -> Text #
sqlType :: Proxy (Key Target) -> SqlType #
toPersistValue :: Key Target -> PersistValue #
fromPersistValue :: PersistValue -> Either Text (Key Target) #
type TargetId = Key Target Source #
data Source Source #
sqlType :: Proxy Source -> SqlType #
onlyUniqueP :: Source -> Unique Source #
requireUniquesP :: Source -> NonEmpty (Unique Source) #
type PersistEntityBackend Source :: Type #
data Key Source :: Type #
data EntityField Source a :: Type #
data Unique Source :: Type #
keyToValues :: Key Source -> [PersistValue] #
keyFromValues :: [PersistValue] -> Either Text (Key Source) #
persistIdField :: EntityField Source (Key Source) #
entityDef :: Monad m => m Source -> EntityDef #
persistFieldDef :: EntityField Source typ -> FieldDef #
toPersistFields :: Source -> [SomePersistField] #
fromPersistValues :: [PersistValue] -> Either Text Source #
persistUniqueKeys :: Source -> [Unique Source] #
persistUniqueToFieldNames :: Unique Source -> [(HaskellName, DBName)] #
persistUniqueToValues :: Unique Source -> [PersistValue] #
fieldLens :: EntityField Source field -> forall (f :: Type -> Type). Functor f => (field -> f field) -> Entity Source -> f (Entity Source) #
toPersistValue :: Source -> PersistValue #
fromPersistValue :: PersistValue -> Either Text Source #
deleteCascade :: MonadIO m => Key Source -> ReaderT backend m () #
toBackendKey :: Key Source -> BackendKey SqlBackend #
fromBackendKey :: BackendKey SqlBackend -> Key Source #
(==) :: Key Source -> Key Source -> Bool #
(/=) :: Key Source -> Key Source -> Bool #
compare :: Key Source -> Key Source -> Ordering #
(<) :: Key Source -> Key Source -> Bool #
(<=) :: Key Source -> Key Source -> Bool #
(>) :: Key Source -> Key Source -> Bool #
(>=) :: Key Source -> Key Source -> Bool #
max :: Key Source -> Key Source -> Key Source #
min :: Key Source -> Key Source -> Key Source #
readsPrec :: Int -> ReadS (Key Source) #
readList :: ReadS [Key Source] #
readPrec :: ReadPrec (Key Source) #
readListPrec :: ReadPrec [Key Source] #
showsPrec :: Int -> Key Source -> ShowS #
show :: Key Source -> String #
showList :: [Key Source] -> ShowS #
toJSON :: Key Source -> Value #
toEncoding :: Key Source -> Encoding #
toJSONList :: [Key Source] -> Value #
toEncodingList :: [Key Source] -> Encoding #
parseJSON :: Value -> Parser (Key Source) #
parseJSONList :: Value -> Parser [Key Source] #
toUrlPiece :: Key Source -> Text #
toEncodedUrlPiece :: Key Source -> Builder #
toHeader :: Key Source -> ByteString #
toQueryParam :: Key Source -> Text #
parseUrlPiece :: Text -> Either Text (Key Source) #
parseHeader :: ByteString -> Either Text (Key Source) #
parseQueryParam :: Text -> Either Text (Key Source) #
fromPathPiece :: Text -> Maybe (Key Source) #
toPathPiece :: Key Source -> Text #
sqlType :: Proxy (Key Source) -> SqlType #
toPersistValue :: Key Source -> PersistValue #
fromPersistValue :: PersistValue -> Either Text (Key Source) #
type SourceId = Key Source Source #
migrationMigrate :: Migration Source #
data Target1 Source #
(==) :: Target1 -> Target1 -> Bool #
(/=) :: Target1 -> Target1 -> Bool #
showsPrec :: Int -> Target1 -> ShowS #
show :: Target1 -> String #
showList :: [Target1] -> ShowS #
sqlType :: Proxy Target1 -> SqlType #
onlyUniqueP :: Target1 -> Unique Target1 #
requireUniquesP :: Target1 -> NonEmpty (Unique Target1) #
type PersistEntityBackend Target1 :: Type #
data Key Target1 :: Type #
data EntityField Target1 a :: Type #
data Unique Target1 :: Type #
keyToValues :: Key Target1 -> [PersistValue] #
keyFromValues :: [PersistValue] -> Either Text (Key Target1) #
persistIdField :: EntityField Target1 (Key Target1) #
entityDef :: Monad m => m Target1 -> EntityDef #
persistFieldDef :: EntityField Target1 typ -> FieldDef #
toPersistFields :: Target1 -> [SomePersistField] #
fromPersistValues :: [PersistValue] -> Either Text Target1 #
persistUniqueKeys :: Target1 -> [Unique Target1] #
persistUniqueToFieldNames :: Unique Target1 -> [(HaskellName, DBName)] #
persistUniqueToValues :: Unique Target1 -> [PersistValue] #
fieldLens :: EntityField Target1 field -> forall (f :: Type -> Type). Functor f => (field -> f field) -> Entity Target1 -> f (Entity Target1) #
toPersistValue :: Target1 -> PersistValue #
fromPersistValue :: PersistValue -> Either Text Target1 #
deleteCascade :: MonadIO m => Key Target1 -> ReaderT backend m () #
toBackendKey :: Key Target1 -> BackendKey SqlBackend #
fromBackendKey :: BackendKey SqlBackend -> Key Target1 #
(==) :: Key Target1 -> Key Target1 -> Bool #
(/=) :: Key Target1 -> Key Target1 -> Bool #
compare :: Key Target1 -> Key Target1 -> Ordering #
(<) :: Key Target1 -> Key Target1 -> Bool #
(<=) :: Key Target1 -> Key Target1 -> Bool #
(>) :: Key Target1 -> Key Target1 -> Bool #
(>=) :: Key Target1 -> Key Target1 -> Bool #
max :: Key Target1 -> Key Target1 -> Key Target1 #
min :: Key Target1 -> Key Target1 -> Key Target1 #
readsPrec :: Int -> ReadS (Key Target1) #
readList :: ReadS [Key Target1] #
readPrec :: ReadPrec (Key Target1) #
readListPrec :: ReadPrec [Key Target1] #
showsPrec :: Int -> Unique Target1 -> ShowS #
show :: Unique Target1 -> String #
showList :: [Unique Target1] -> ShowS #
showsPrec :: Int -> Key Target1 -> ShowS #
show :: Key Target1 -> String #
showList :: [Key Target1] -> ShowS #
toJSON :: Key Target1 -> Value #
toEncoding :: Key Target1 -> Encoding #
toJSONList :: [Key Target1] -> Value #
toEncodingList :: [Key Target1] -> Encoding #
parseJSON :: Value -> Parser (Key Target1) #
parseJSONList :: Value -> Parser [Key Target1] #
toUrlPiece :: Key Target1 -> Text #
toEncodedUrlPiece :: Key Target1 -> Builder #
toHeader :: Key Target1 -> ByteString #
toQueryParam :: Key Target1 -> Text #
parseUrlPiece :: Text -> Either Text (Key Target1) #
parseHeader :: ByteString -> Either Text (Key Target1) #
parseQueryParam :: Text -> Either Text (Key Target1) #
fromPathPiece :: Text -> Maybe (Key Target1) #
toPathPiece :: Key Target1 -> Text #
sqlType :: Proxy (Key Target1) -> SqlType #
toPersistValue :: Key Target1 -> PersistValue #
fromPersistValue :: PersistValue -> Either Text (Key Target1) #
type Target1Id = Key Target1 Source #
data Source1 Source #
sqlType :: Proxy Source1 -> SqlType #
onlyUniqueP :: Source1 -> Unique Source1 #
requireUniquesP :: Source1 -> NonEmpty (Unique Source1) #
type PersistEntityBackend Source1 :: Type #
data Key Source1 :: Type #
data EntityField Source1 a :: Type #
data Unique Source1 :: Type #
keyToValues :: Key Source1 -> [PersistValue] #
keyFromValues :: [PersistValue] -> Either Text (Key Source1) #
persistIdField :: EntityField Source1 (Key Source1) #
entityDef :: Monad m => m Source1 -> EntityDef #
persistFieldDef :: EntityField Source1 typ -> FieldDef #
toPersistFields :: Source1 -> [SomePersistField] #
fromPersistValues :: [PersistValue] -> Either Text Source1 #
persistUniqueKeys :: Source1 -> [Unique Source1] #
persistUniqueToFieldNames :: Unique Source1 -> [(HaskellName, DBName)] #
persistUniqueToValues :: Unique Source1 -> [PersistValue] #
fieldLens :: EntityField Source1 field -> forall (f :: Type -> Type). Functor f => (field -> f field) -> Entity Source1 -> f (Entity Source1) #
toPersistValue :: Source1 -> PersistValue #
fromPersistValue :: PersistValue -> Either Text Source1 #
deleteCascade :: MonadIO m => Key Source1 -> ReaderT backend m () #
toBackendKey :: Key Source1 -> BackendKey SqlBackend #
fromBackendKey :: BackendKey SqlBackend -> Key Source1 #
(==) :: Key Source1 -> Key Source1 -> Bool #
(/=) :: Key Source1 -> Key Source1 -> Bool #
compare :: Key Source1 -> Key Source1 -> Ordering #
(<) :: Key Source1 -> Key Source1 -> Bool #
(<=) :: Key Source1 -> Key Source1 -> Bool #
(>) :: Key Source1 -> Key Source1 -> Bool #
(>=) :: Key Source1 -> Key Source1 -> Bool #
max :: Key Source1 -> Key Source1 -> Key Source1 #
min :: Key Source1 -> Key Source1 -> Key Source1 #
readsPrec :: Int -> ReadS (Key Source1) #
readList :: ReadS [Key Source1] #
readPrec :: ReadPrec (Key Source1) #
readListPrec :: ReadPrec [Key Source1] #
showsPrec :: Int -> Key Source1 -> ShowS #
show :: Key Source1 -> String #
showList :: [Key Source1] -> ShowS #
toJSON :: Key Source1 -> Value #
toEncoding :: Key Source1 -> Encoding #
toJSONList :: [Key Source1] -> Value #
toEncodingList :: [Key Source1] -> Encoding #
parseJSON :: Value -> Parser (Key Source1) #
parseJSONList :: Value -> Parser [Key Source1] #
toUrlPiece :: Key Source1 -> Text #
toEncodedUrlPiece :: Key Source1 -> Builder #
toHeader :: Key Source1 -> ByteString #
toQueryParam :: Key Source1 -> Text #
parseUrlPiece :: Text -> Either Text (Key Source1) #
parseHeader :: ByteString -> Either Text (Key Source1) #
parseQueryParam :: Text -> Either Text (Key Source1) #
fromPathPiece :: Text -> Maybe (Key Source1) #
toPathPiece :: Key Source1 -> Text #
sqlType :: Proxy (Key Source1) -> SqlType #
toPersistValue :: Key Source1 -> PersistValue #
fromPersistValue :: PersistValue -> Either Text (Key Source1) #
type Source1Id = Key Source1 Source #
migrationAddCol :: Migration Source #
specsWith :: MonadIO m => RunDb SqlBackend m -> Spec Source #