# Behavioural tests: free to rewrite the code > I think we need a larger project to turn most of the tests into > behavioural ones so that we are free to rewrite the code. Planned 2026-11-03 by the user and the coordinator, from an inventory agent's survey. The `e2e` line (kbdin, mousein) is its first step. ## Decided by the user - **A test goes in and comes out through public surfaces only:** the 9P tree (pane files, `ctl`, `look`/`exec`, `log`, `/screen`, `kbdin`, `mousein`), the process (flags, daemon, attach, signals, terminal bytes), and files on disk and effects. A rewrite that keeps those keeps its tests. - **T1, in-process 9P, is the main tier.** The core is driven only through `serveFs` (src/ninep/testing.zig's `call`, `rd`, `wr`): as behavioural as a client on a socket, and milliseconds a case. - **Process-level tests (T2) get a Zig runner, not Python:** test/snapshot.zig, the `.snap` runner, which already forks the app in a pty and has a 9P client (`snap9p`), grows 9P verbs (`9pwrite`, `9pexpect`, `signal`). The Python suites (test/fs.py and the rest) stay as examples of scripting a session and are not grown. - **Layout (from a ponytail review, 2026-11-03):** - **test/session.zig is the T1 `Session`:** a 9P client's walk, open, read or write, clunk, by path, with the core opaque. - **test/behaviour/