## E2E test pattern for camera-dependent tests

Tests in `tests/test_e2e.py` connect to real cameras. They auto-skip when `REOLINK_HOST` is not set.

### Pattern

- Module-level `pytestmark` with `pytest.mark.e2e` and `skipif(not REOLINK_HOST)`
- Custom marker registered in `pyproject.toml` under `[tool.pytest.ini_options]`
- Tests call real async `_run()` functions with `json=True`
- Capture stdout via `capsys`, parse as JSON for assertions
- Only test read-only commands — never change camera state

### Running

```bash
# E2E against a specific camera
REOLINK_HOST=10.8.12.26 REOLINK_PASSWORD=... uv run pytest tests/test_e2e.py -v

# All tests (e2e auto-skips without env vars)
uv run pytest tests/ -v
```

### Adding new e2e tests

1. Import the relevant `_run` function from `reolink_ctl.commands.*`
2. Call with `_args(json=True, ...)` and the `config` fixture
3. Parse output with `_parse_json(capsys)`
4. Assert on returned dict keys/values
