apptest

package
v0.19.2 Latest Latest
Warning

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

Go to latest
Published: Jan 30, 2026 License: Apache-2.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewTestApp

func NewTestApp(t testing.TB, options ...fx.Option) (*app.App, func())

NewTestApp creates a test application with Fx dependency injection. Returns the app instance and a cleanup function.

func NewTestAppWithErr

func NewTestAppWithErr(t testing.TB, options ...fx.Option) (*app.App, func(), error)

NewTestAppWithErr creates a test application and returns any startup errors. Useful for testing error conditions during app initialization.

Types

type MockConfig

type MockConfig struct{}

MockConfig implements config.Config for testing without file dependencies.

func (*MockConfig) Unmarshal

func (*MockConfig) Unmarshal(_ string, _ any) error

Jump to

Keyboard shortcuts

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