Parse command-line arguments
()
| 23 | |
| 24 | |
| 25 | def parse_args(): |
| 26 | """Parse command-line arguments""" |
| 27 | parser = argparse.ArgumentParser( |
| 28 | description="Run WASM Playwright tests for FastLED examples" |
| 29 | ) |
| 30 | parser.add_argument( |
| 31 | "example", |
| 32 | nargs="?", |
| 33 | default="wasm", |
| 34 | help="Example name to test (e.g., 'Blink', 'wasm')", |
| 35 | ) |
| 36 | parser.add_argument( |
| 37 | "--gfx", |
| 38 | default="0", |
| 39 | help="Graphics mode parameter (default: 0)", |
| 40 | ) |
| 41 | return parser.parse_args() |
| 42 | |
| 43 | |
| 44 | # Ensure Playwright browsers are installed |