tree: c15736f3fa6564bfc16f46a6b9d449e1691a5967 [path history] [tgz]
  1. generated/
  2. scenarios/
  3. mod.rs
  4. README.md
  5. scenarios_list.json
  6. trace_generator.py
src/starnix/lib/line_discipline/testing/README.md

Line Discipline Trace Generator

This directory contains trace_generator.py, a utility for generating golden trace files on Linux to verifying Starnix line discipline behavior.

Usage

The generator MUST be run on a Linux host (not Fuchsia/Starnix) as it captures the behavior of the host's PTY implementation.

Generating Traces

To generate all trace files:

python3 src/starnix/lib/line_discipline/testing/trace_generator.py

This will generate trace files in src/starnix/lib/line_discipline/testing/generated/.

Note: You must run this script manually whenever you change or add a scenario.

Adding New Tests

  1. Add the a scenario to the scenarios directory.
  2. Add the the name of the scenario to scenarios_list.json.
  3. Run the generator to produce the JSON trace.