Fix #5: keep browse control visible
This commit is contained in:
parent
40aa66d164
commit
1b19d5eca2
2 changed files with 14 additions and 7 deletions
|
|
@ -3,7 +3,7 @@
|
|||
from unittest.mock import Mock
|
||||
|
||||
import pytest
|
||||
from textual.widgets import Input, RadioButton, Static
|
||||
from textual.widgets import Button, Input, RadioButton, Static
|
||||
|
||||
from hosts.core.import_export import (
|
||||
ExportFormat,
|
||||
|
|
@ -67,6 +67,14 @@ async def test_export_browser_lets_the_user_choose_a_destination_directory():
|
|||
async with app.run_test(size=(120, 40)) as pilot:
|
||||
await pilot.press("ctrl+x")
|
||||
await pilot.pause()
|
||||
browse = app.screen.query_one("#browse-button", Button)
|
||||
path_input = app.screen.query_one("#path-input", Input)
|
||||
container = app.screen.query_one("#format-container")
|
||||
assert browse.region.width > 0
|
||||
assert browse.region.x >= path_input.region.x
|
||||
assert browse.region.y >= path_input.region.bottom
|
||||
assert browse.region.right <= container.region.right
|
||||
assert browse.region.bottom <= container.region.bottom
|
||||
await pilot.press("tab")
|
||||
await pilot.press("enter")
|
||||
await pilot.pause()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue