app: add slash commands

This commit is contained in:
Username
2026-02-28 14:11:51 +01:00
parent 15fbf0040a
commit 4bf8adc5e2
2 changed files with 94 additions and 4 deletions

View File

@@ -256,6 +256,39 @@ async def test_statusbar_deaf():
assert "\u2298" in rendered
@pytest.mark.asyncio
async def test_statusbar_muted():
app = StatusBarApp()
async with app.run_test(size=(80, 5)) as _pilot:
bar = app.query_one("#status", StatusBar)
bar.self_mute = True
rendered = bar.render()
assert "\u2715" in rendered
@pytest.mark.asyncio
async def test_statusbar_muted_compact():
app = StatusBarApp()
async with app.run_test(size=(30, 5)) as pilot:
bar = app.query_one("#status", StatusBar)
bar.self_mute = True
await pilot.resize_terminal(30, 5)
await pilot.pause()
rendered = bar.render()
assert "\u2715" in rendered
@pytest.mark.asyncio
async def test_statusbar_muted_medium():
app = StatusBarApp()
async with app.run_test(size=(50, 5)) as _pilot:
bar = app.query_one("#status", StatusBar)
bar.self_mute = True
rendered = bar.render()
assert "\u2715" in rendered
assert "mute" in rendered
@pytest.mark.asyncio
async def test_statusbar_reconnecting():
app = StatusBarApp()