| 38 | |
| 39 | |
| 40 | def parse_args(): |
| 41 | parser = argparse.ArgumentParser( |
| 42 | description="Test WASM audio drag-and-drop and buffered sample pipeline" |
| 43 | ) |
| 44 | parser.add_argument( |
| 45 | "example", |
| 46 | nargs="?", |
| 47 | default="AudioUrl", |
| 48 | help="Example name to test (default: AudioUrl)", |
| 49 | ) |
| 50 | parser.add_argument( |
| 51 | "--mp3", |
| 52 | type=str, |
| 53 | default=None, |
| 54 | help="Path to MP3 file for drag-and-drop test", |
| 55 | ) |
| 56 | parser.add_argument( |
| 57 | "--timeout", |
| 58 | type=int, |
| 59 | default=45, |
| 60 | help="Timeout in seconds for audio pipeline verification (default: 45)", |
| 61 | ) |
| 62 | parser.add_argument( |
| 63 | "--enable-vibe-reactive", |
| 64 | action="store_true", |
| 65 | default=False, |
| 66 | help="Enable the 'Enable Vibe Reactive' checkbox after audio loads", |
| 67 | ) |
| 68 | parser.add_argument( |
| 69 | "--headed", |
| 70 | action="store_true", |
| 71 | default=False, |
| 72 | help="Run browser in headed (visible) mode for debugging", |
| 73 | ) |
| 74 | parser.add_argument( |
| 75 | "--monitor-duration", |
| 76 | type=int, |
| 77 | default=30, |
| 78 | help="How long (seconds) to monitor after vibe reactive is enabled (default: 30)", |
| 79 | ) |
| 80 | return parser.parse_args() |
| 81 | |
| 82 | |
| 83 | def install_playwright_browsers(): |