Skip to content

Commit 5e8ee00

Browse files
Add test of breakpoints
1 parent 54f420a commit 5e8ee00

File tree

1 file changed

+24
-5
lines changed

1 file changed

+24
-5
lines changed

tests/snapshot_tests/test_snapshots.py

Lines changed: 24 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4081,23 +4081,42 @@ class BreakpointApp(App):
40814081
(120, "-very-wide"),
40824082
]
40834083

4084+
VERTICAL_BREAKPOINTS = [
4085+
(0, "-low"),
4086+
(30, "-middle"),
4087+
(40, "-high"),
4088+
(50, "-very-high"),
4089+
]
4090+
40844091
CSS = """
40854092
Screen {
40864093
&.-narrow {
4087-
Grid { grid-size: 1; }
4094+
Grid { grid-columns: 20; }
40884095
}
40894096
&.-normal {
4090-
Grid { grid-size: 2; }
4097+
Grid { grid-columns: 40; }
40914098
}
40924099
&.-wide {
4093-
Grid { grid-size: 4; }
4100+
Grid { grid-columns: 80; }
40944101
}
40954102
&.-very-wide {
4096-
Grid { grid-size: 6; }
4103+
Grid { grid-columns: 120; }
4104+
}
4105+
&.-low {
4106+
Grid { grid-rows: 1; }
4107+
}
4108+
&.-middle {
4109+
Grid { grid-rows: 2; }
4110+
}
4111+
&.-high {
4112+
Grid { grid-rows: 4; }
4113+
}
4114+
&.-very-high {
4115+
Grid { grid-rows: 6; }
40974116
}
40984117
}
40994118
"""
4100-
4119+
41014120
def compose(self) -> ComposeResult:
41024121
with Grid():
41034122
for n in range(16):

0 commit comments

Comments
 (0)