Skip to content

Docs: add expected-output note for isolated pytest trace store #244

@aaronlab

Description

@aaronlab

Goal

Add a small expected-output / verification note for the isolated pytest trace-store recipe in examples/README.md.

Scope

Please keep this docs-only and limited to examples/README.md unless you find an existing command in that file is wrong.

A good target section is the pytest example just before ## Public Export Flow, where the docs show:

def test_browsertrace_trace_uses_temp_store(tmp_path, monkeypatch):
    monkeypatch.setenv("BROWSERTRACE_HOME", str(tmp_path))
    ...
    assert (tmp_path / "db.sqlite").exists()

Add 2-4 sentences that tell a first-time contributor what to expect after this test/recipe works. For example:

  • the isolated store should contain db.sqlite under the temporary path, not ~/.browsertrace/
  • the recorded run should be named pytest isolated trace
  • passing Tracer(home=tmp_path) is the safer option if the module imports BrowserTrace before setting BROWSERTRACE_HOME
  • no screenshots, browser, network, or API keys are required for this recipe

Verification

Please include the exact commands you ran in the PR. A good local docs check is:

uv run --python 3.11 --extra dev pytest tests/test_metadata.py -q

If you run the example manually, mention whether you used BROWSERTRACE_HOME or Tracer(home=tmp_path).

Non-goals

  • Do not change trace storage implementation.
  • Do not add generated SQLite databases or trace artifacts to the repository.
  • Do not change unrelated examples.

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationImprovements or additions to documentationgood first issueGood for newcomershelp wantedExtra attention is needed

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions