Header menu logo FSharp.ATProto

TestFactory Type

Factory methods for creating domain objects with sensible defaults. Useful for testing consumers of the library without needing a live API. All parameters are optional; unspecified fields use deterministic default values.

Static members

Static member Description

TestFactory.BlockRef(?uri)

Full Usage: TestFactory.BlockRef(?uri)

Parameters:
Returns: BlockRef

Create a BlockRef with a default AT-URI. Override by passing a uri.

?uri : AtUri
Returns: BlockRef

TestFactory.FeedItem(?post, ?reason, ?replyParent)

Full Usage: TestFactory.FeedItem(?post, ?reason, ?replyParent)

Parameters:
Returns: FeedItem

Create a FeedItem wrapping a TimelinePost with no feed reason.

?post : TimelinePost
?reason : FeedReason
?replyParent : TimelinePost
Returns: FeedItem

TestFactory.FollowRef(?uri)

Full Usage: TestFactory.FollowRef(?uri)

Parameters:
Returns: FollowRef

Create a FollowRef with a default AT-URI. Override by passing a uri.

?uri : AtUri
Returns: FollowRef

TestFactory.LikeRef(?uri)

Full Usage: TestFactory.LikeRef(?uri)

Parameters:
Returns: LikeRef

Create a LikeRef with a default AT-URI. Override by passing a uri.

?uri : AtUri
Returns: LikeRef

TestFactory.Notification(?recordUri, ?author, ?content, ?isRead, ?indexedAt)

Full Usage: TestFactory.Notification(?recordUri, ?author, ?content, ?isRead, ?indexedAt)

Parameters:
Returns: Notification

Create a Notification with sensible defaults.

?recordUri : AtUri
?author : ProfileSummary
?content : NotificationContent
?isRead : bool
?indexedAt : DateTimeOffset
Returns: Notification

TestFactory.PostRef(?uri, ?cid)

Full Usage: TestFactory.PostRef(?uri, ?cid)

Parameters:
Returns: PostRef

Create a PostRef with sensible defaults. Override any field by passing named parameters.

?uri : AtUri
?cid : Cid
Returns: PostRef

TestFactory.Profile(?did, ?handle, ?displayName, ?description, ?avatar, ?banner, ?postsCount, ?followersCount, ?followsCount, ?isFollowing, ?isFollowedBy, ?isBlocking, ?isBlockedBy, ?isMuted)

Full Usage: TestFactory.Profile(?did, ?handle, ?displayName, ?description, ?avatar, ?banner, ?postsCount, ?followersCount, ?followsCount, ?isFollowing, ?isFollowedBy, ?isBlocking, ?isBlockedBy, ?isMuted)

Parameters:
    ?did : Did
    ?handle : Handle
    ?displayName : string
    ?description : string
    ?avatar : string
    ?banner : string
    ?postsCount : int64
    ?followersCount : int64
    ?followsCount : int64
    ?isFollowing : bool
    ?isFollowedBy : bool
    ?isBlocking : bool
    ?isBlockedBy : bool
    ?isMuted : bool

Returns: Profile

Create a Profile with sensible defaults. Override any field by passing named parameters.

?did : Did
?handle : Handle
?displayName : string
?description : string
?avatar : string
?banner : string
?postsCount : int64
?followersCount : int64
?followsCount : int64
?isFollowing : bool
?isFollowedBy : bool
?isBlocking : bool
?isBlockedBy : bool
?isMuted : bool
Returns: Profile

TestFactory.ProfileSummary(?did, ?handle, ?displayName, ?avatar)

Full Usage: TestFactory.ProfileSummary(?did, ?handle, ?displayName, ?avatar)

Parameters:
    ?did : Did
    ?handle : Handle
    ?displayName : string
    ?avatar : string

Returns: ProfileSummary

Create a ProfileSummary with sensible defaults. Override any field by passing named parameters.

?did : Did
?handle : Handle
?displayName : string
?avatar : string
Returns: ProfileSummary

TestFactory.RepostRef(?uri)

Full Usage: TestFactory.RepostRef(?uri)

Parameters:
Returns: RepostRef

Create a RepostRef with a default AT-URI. Override by passing a uri.

?uri : AtUri
Returns: RepostRef

TestFactory.TimelinePost(?uri, ?cid, ?author, ?text, ?facets, ?likeCount, ?repostCount, ?replyCount, ?quoteCount, ?indexedAt, ?isLiked, ?isReposted, ?isBookmarked)

Full Usage: TestFactory.TimelinePost(?uri, ?cid, ?author, ?text, ?facets, ?likeCount, ?repostCount, ?replyCount, ?quoteCount, ?indexedAt, ?isLiked, ?isReposted, ?isBookmarked)

Parameters:
    ?uri : AtUri
    ?cid : Cid
    ?author : ProfileSummary
    ?text : string
    ?facets : Facet list
    ?likeCount : int64
    ?repostCount : int64
    ?replyCount : int64
    ?quoteCount : int64
    ?indexedAt : DateTimeOffset
    ?isLiked : bool
    ?isReposted : bool
    ?isBookmarked : bool

Returns: TimelinePost

Create a TimelinePost with sensible defaults. Override any field by passing named parameters.

?uri : AtUri
?cid : Cid
?author : ProfileSummary
?text : string
?facets : Facet list
?likeCount : int64
?repostCount : int64
?replyCount : int64
?quoteCount : int64
?indexedAt : DateTimeOffset
?isLiked : bool
?isReposted : bool
?isBookmarked : bool
Returns: TimelinePost

Type something to start searching.