testkit

package
v0.6.4 Latest Latest
Warning

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

Go to latest
Published: Oct 23, 2026 License: Apache-2.0 Imports: 9 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

Overview

Package testkit builds a demo home for tests and the browser test server: a git repository, Claude Code sessions and Codex threads from the agents' fixtures, with paths pointed at it. It is test infrastructure, not part of hopsesh.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DemoHome

func DemoHome(h string) error

DemoHome fills h (which should be empty) with a repository at git/demo whose remote is github.com/example/demo, Claude Code 2.1.284 sessions and Codex 0.153.2 threads in it.

func Env

func Env(h string) map[string]string

Env is the environment that points hopsesh and both agents at a demo home h: its own configuration, this machine named "studio", Tailscale left out of discovery, and (outside Windows) a PATH of system folders only, so no real agent program runs.

Types

This section is empty.

Directories

Path Synopsis
Package fakeagent is the stand-in Claude Code and Codex the tests (and the Windows screenshots in CI) run in place of the real agents.
Package fakeagent is the stand-in Claude Code and Codex the tests (and the Windows screenshots in CI) run in place of the real agents.
Package fakecloud is the stand-in for the vendors' clouds that the tests run against: cloud sessions kept as JSON files in $FAKE_CLOUD_DIR, a local bare repository standing in for the GitHub repository the clouds clone and push, the cloud verbs of the stand-in claude and codex programs (see internal/testkit/fakeagent), a small third-party-style cloud CLI of its own (`fakecloud remote …`, driven by Stub), and `fakecloud work <id>`, which plays the cloud agent.
Package fakecloud is the stand-in for the vendors' clouds that the tests run against: cloud sessions kept as JSON files in $FAKE_CLOUD_DIR, a local bare repository standing in for the GitHub repository the clouds clone and push, the cloud verbs of the stand-in claude and codex programs (see internal/testkit/fakeagent), a small third-party-style cloud CLI of its own (`fakecloud remote …`, driven by Stub), and `fakecloud work <id>`, which plays the cloud agent.
Package termfake is a stand-in program for the terminal's tests: it runs in a tab, asks the terminal what it is (DA1 and DA2, as Claude Code does), says what came back, and then does what keys ask, so a test can drive a tab end to end through the real window.
Package termfake is a stand-in program for the terminal's tests: it runs in a tab, asks the terminal what it is (DA1 and DA2, as Claude Code does), says what came back, and then does what keys ask, so a test can drive a tab end to end through the real window.

Jump to

Keyboard shortcuts

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