session

package
v0.0.40 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type TestSession

type TestSession struct {
	BaseURL string
	OrgID   uuid.UUID
	Account *models.Account
	// contains filtered or unexported fields
}

TestSession handles per-test actions: db, auth, and page ops.

func NewTestSession

func NewTestSession(t *testing.T, context pw.BrowserContext, page pw.Page, timeoutMs float64, baseURL string) *TestSession

func (*TestSession) AssertDisabled

func (s *TestSession) AssertDisabled(q queries.Query)

func (*TestSession) AssertText

func (s *TestSession) AssertText(text string)

func (*TestSession) AssertURLContains

func (s *TestSession) AssertURLContains(part string)

func (*TestSession) AssertVisible

func (s *TestSession) AssertVisible(q queries.Query)

func (*TestSession) Click

func (s *TestSession) Click(q queries.Query)

func (*TestSession) Close

func (s *TestSession) Close()

func (*TestSession) DragAndDrop

func (s *TestSession) DragAndDrop(source queries.Query, target queries.Query, offsetX, offsetY int)

func (*TestSession) FillIn

func (s *TestSession) FillIn(q queries.Query, value string)

func (*TestSession) HoverOver

func (s *TestSession) HoverOver(q queries.Query)

func (*TestSession) Login

func (s *TestSession) Login()

func (*TestSession) Page

func (s *TestSession) Page() pw.Page

Page exposes the underlying playwright Page to satisfy queries.Runner.

func (*TestSession) ScrollToTheBottomOfPage

func (s *TestSession) ScrollToTheBottomOfPage()

func (*TestSession) Sleep

func (s *TestSession) Sleep(ms int)

func (*TestSession) Start

func (s *TestSession) Start()

func (*TestSession) StartWithoutUser

func (s *TestSession) StartWithoutUser()

StartWithoutUser resets the database but does not seed any user or organization records. This is useful for flows that expect an empty instance, such as the first-run owner setup.

func (*TestSession) TakeScreenshot

func (s *TestSession) TakeScreenshot()

func (*TestSession) Visit

func (s *TestSession) Visit(path string)

func (*TestSession) VisitHomePage

func (s *TestSession) VisitHomePage()

Jump to

Keyboard shortcuts

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