testutil

package
v1.0.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 13, 2026 License: Apache-2.0 Imports: 3 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Provider

type Provider struct {
	Fail                func(string)
	SearchPostsFunc     func(context.Context, string, int) (domain.Page[domain.Post], error)
	GetPostFunc         func(context.Context, string) (domain.Post, error)
	GetPostRepliesFunc  func(context.Context, string, int) (domain.Page[domain.Reply], error)
	GetProfileFunc      func(context.Context, string) (domain.Profile, error)
	GetProfilePostsFunc func(context.Context, string, int) (domain.Page[domain.Post], error)
	InfoValue           provider.Info
}

func (*Provider) GetPost

func (p *Provider) GetPost(ctx context.Context, post string) (domain.Post, error)

func (*Provider) GetPostReplies

func (p *Provider) GetPostReplies(ctx context.Context, post string, limit int) (domain.Page[domain.Reply], error)

func (*Provider) GetProfile

func (p *Provider) GetProfile(ctx context.Context, username string) (domain.Profile, error)

func (*Provider) GetProfilePosts

func (p *Provider) GetProfilePosts(ctx context.Context, username string, limit int) (domain.Page[domain.Post], error)

func (*Provider) Info

func (p *Provider) Info() provider.Info

func (*Provider) SearchPosts

func (p *Provider) SearchPosts(ctx context.Context, query string, limit int) (domain.Page[domain.Post], error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL