# crossbario/autobahn-testsuite architecture

> Architecture diagram of the GitHub repository crossbario/autobahn-testsuite, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-06). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/crossbario/autobahn-testsuite
- Repository: https://github.com/crossbario/autobahn-testsuite

## Overview

Autobahn|Testsuite runs WebSocket conformance and robustness checks against client or server implementations, then records and reports outcomes. The main workflow is selecting a test mode and specification in `wstest.py`, running protocol cases through the fuzzing service, and generating results. The repository also exposes WAMP testing, testee endpoints, echo/broadcast utilities, mass-connect, and wsperf tools. Some auxiliary implementations were not excerpted, so their internal connections are shown only where the README documents them.

Main entry points: [`autobahntestsuite/autobahntestsuite/wstest.py`](https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/wstest.py) (Mode dispatcher), [`autobahntestsuite/autobahntestsuite/fuzzing.py`](https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/fuzzing.py) (WebSocket fuzz runner), [`autobahntestsuite/autobahntestsuite/wampfuzzing.py`](https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/wampfuzzing.py) (WAMP test runner), [`autobahntestsuite/autobahntestsuite/wampcase/wampcase.py`](https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/wampcase/wampcase.py) (WAMP case behavior)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_entry["Modes and orchestration"]
  node_modes["Mode dispatcher<br/>[wstest.py]"]
  node_spec["Test specification"]
  node_testee["Testee endpoints<br/>[testee.py]"]
end

subgraph group_websocket["WebSocket conformance"]
  node_fuzz["WebSocket fuzz runner<br/>[fuzzing.py]"]
  node_caseset["Case selection<br/>[caseset.py]"]
  node_catalog["Protocol case catalog<br/>[__init__.py]"]
  node_casebase["Case behavior<br/>[case.py]"]
  node_results["Test results<br/>[testrun.py]"]
  node_report["HTML reports<br/>[report.py]"]
  node_testdb[("Result database<br/>[testdb.py]")]
end

subgraph group_wamp["WAMP testing"]
  node_wampfuzz["WAMP test runner<br/>[wampfuzzing.py]"]
  node_wampcases["WAMP case catalog<br/>[__init__.py]"]
  node_wampcase["WAMP case behavior<br/>[wampcase.py]"]
end

subgraph group_tools["Developer tools"]
  node_echo["Echo server/client<br/>[echo.py]"]
  node_broadcast["Broadcast server<br/>[broadcast.py]"]
  node_mass["Mass-connect tool<br/>[massconnect.py]"]
  node_perfcontrol["wsperf controller<br/>[wsperfcontrol.py]"]
  node_perfmaster["wsperf master<br/>[wsperfmaster.py]"]
end

node_user(("Implementer"))
node_peer(("WebSocket implementation"))
node_wamppeer(("WAMP implementation"))

node_user -->|"selects mode"| node_modes
node_modes -->|"loads configuration"| node_spec
node_modes -->|"starts fuzzing"| node_fuzz
node_fuzz -->|"selects cases"| node_caseset
node_caseset -.->|"uses catalog"| node_catalog
node_catalog -.->|"inherits behavior"| node_casebase
node_fuzz -->|"runs cases"| node_casebase
node_fuzz -.->|"tests protocol"| node_peer
node_fuzz -.->|"produces outcomes"| node_results
node_fuzz -->|"generates reports"| node_report
node_results -.->|"persists results"| node_testdb
node_report -.->|"reads results"| node_testdb
node_modes -->|"starts testee"| node_testee
node_modes -->|"starts WAMP tests"| node_wampfuzz
node_wampfuzz -.->|"selects cases"| node_wampcases
node_wampcases -->|"provides cases"| node_wampcase
node_wampfuzz -.->|"runs cases"| node_wampcase
node_wampcase -.->|"tests protocol"| node_wamppeer
node_modes -->|"starts mode"| node_echo
node_modes -->|"starts mode"| node_broadcast
node_modes -->|"starts mode"| node_mass
node_modes -->|"starts controller"| node_perfcontrol
node_modes -->|"starts master"| node_perfmaster
node_perfcontrol -.->|"coordinates performance"| node_perfmaster

click node_modes "https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/wstest.py"
click node_testee "https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/testee.py"
click node_fuzz "https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/fuzzing.py"
click node_caseset "https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/caseset.py"
click node_catalog "https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/case/__init__.py"
click node_casebase "https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/case/case.py"
click node_results "https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/testrun.py"
click node_report "https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/report.py"
click node_testdb "https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/testdb.py"
click node_wampfuzz "https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/wampfuzzing.py"
click node_wampcases "https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/wampcase/__init__.py"
click node_wampcase "https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/wampcase/wampcase.py"
click node_echo "https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/echo.py"
click node_broadcast "https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/broadcast.py"
click node_mass "https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/massconnect.py"
click node_perfcontrol "https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/wsperfcontrol.py"
click node_perfmaster "https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/wsperfmaster.py"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_modes,node_spec,node_testee toneBlue
class node_fuzz,node_caseset,node_catalog,node_casebase,node_results,node_report,node_testdb toneAmber
class node_wampfuzz,node_wampcases,node_wampcase toneMint
class node_echo,node_broadcast,node_mass,node_perfcontrol,node_perfmaster toneRose
class node_user,node_peer,node_wamppeer toneIndigo
```

## Components

### Modes and orchestration

- [Mode dispatcher](https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/wstest.py): `autobahntestsuite/autobahntestsuite/wstest.py`
- **Test specification**
- [Testee endpoints](https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/testee.py): `autobahntestsuite/autobahntestsuite/testee.py`

### WebSocket conformance

- [WebSocket fuzz runner](https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/fuzzing.py): `autobahntestsuite/autobahntestsuite/fuzzing.py`
- [Case selection](https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/caseset.py): `autobahntestsuite/autobahntestsuite/caseset.py`
- [Protocol case catalog](https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/case/__init__.py): `autobahntestsuite/autobahntestsuite/case/__init__.py`
- [Case behavior](https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/case/case.py): `autobahntestsuite/autobahntestsuite/case/case.py`
- [Test results](https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/testrun.py): `autobahntestsuite/autobahntestsuite/testrun.py`
- [HTML reports](https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/report.py): `autobahntestsuite/autobahntestsuite/report.py`
- [Result database](https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/testdb.py): `autobahntestsuite/autobahntestsuite/testdb.py`

### WAMP testing

- [WAMP test runner](https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/wampfuzzing.py): `autobahntestsuite/autobahntestsuite/wampfuzzing.py`
- [WAMP case catalog](https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/wampcase/__init__.py): `autobahntestsuite/autobahntestsuite/wampcase/__init__.py`
- [WAMP case behavior](https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/wampcase/wampcase.py): `autobahntestsuite/autobahntestsuite/wampcase/wampcase.py`

### Developer tools

- [Echo server/client](https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/echo.py): `autobahntestsuite/autobahntestsuite/echo.py`
- [Broadcast server](https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/broadcast.py): `autobahntestsuite/autobahntestsuite/broadcast.py`
- [Mass-connect tool](https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/massconnect.py): `autobahntestsuite/autobahntestsuite/massconnect.py`
- [wsperf controller](https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/wsperfcontrol.py): `autobahntestsuite/autobahntestsuite/wsperfcontrol.py`
- [wsperf master](https://github.com/crossbario/autobahn-testsuite/blob/master/autobahntestsuite/autobahntestsuite/wsperfmaster.py): `autobahntestsuite/autobahntestsuite/wsperfmaster.py`

### Other components

- **Implementer**
- **WebSocket implementation**
- **WAMP implementation**

## Connections

- Implementer → Mode dispatcher: selects mode (evidence: `autobahntestsuite/autobahntestsuite/wstest.py`)
- Mode dispatcher → Test specification: loads configuration (evidence: `autobahntestsuite/autobahntestsuite/wstest.py`)
- Mode dispatcher → WebSocket fuzz runner: starts fuzzing (evidence: `autobahntestsuite/autobahntestsuite/wstest.py`)
- WebSocket fuzz runner → Case selection: selects cases (evidence: `autobahntestsuite/autobahntestsuite/fuzzing.py`)
- Case selection → Protocol case catalog: uses catalog
- Protocol case catalog → Case behavior: inherits behavior
- WebSocket fuzz runner → Case behavior: runs cases (evidence: `autobahntestsuite/autobahntestsuite/fuzzing.py`)
- WebSocket fuzz runner → WebSocket implementation: tests protocol
- WebSocket fuzz runner → Test results: produces outcomes
- WebSocket fuzz runner → HTML reports: generates reports (evidence: `autobahntestsuite/autobahntestsuite/fuzzing.py`)
- Test results → Result database: persists results (evidence: `autobahntestsuite/autobahntestsuite/testdb.py`)
- HTML reports → Result database: reads results
- Mode dispatcher → Testee endpoints: starts testee (evidence: `autobahntestsuite/autobahntestsuite/wstest.py`)
- Mode dispatcher → WAMP test runner: starts WAMP tests (evidence: `autobahntestsuite/autobahntestsuite/wstest.py`)
- WAMP test runner → WAMP case catalog: selects cases
- WAMP case catalog → WAMP case behavior: provides cases (evidence: `autobahntestsuite/autobahntestsuite/wampcase/__init__.py`)
- WAMP test runner → WAMP case behavior: runs cases
- WAMP case behavior → WAMP implementation: tests protocol
- Mode dispatcher → Echo server/client: starts mode (evidence: `autobahntestsuite/autobahntestsuite/wstest.py`)
- Mode dispatcher → Broadcast server: starts mode (evidence: `autobahntestsuite/autobahntestsuite/wstest.py`)
- Mode dispatcher → Mass-connect tool: starts mode (evidence: `autobahntestsuite/autobahntestsuite/wstest.py`)
- Mode dispatcher → wsperf controller: starts controller (evidence: `autobahntestsuite/autobahntestsuite/wstest.py`)
- Mode dispatcher → wsperf master: starts master (evidence: `autobahntestsuite/autobahntestsuite/wstest.py`)
- wsperf controller → wsperf master: coordinates performance
