mirror of
https://github.com/Textualize/textual.git
synced 2025-10-17 02:38:12 +03:00
Ensure test accounts for negative values
This commit is contained in:
@@ -54,7 +54,7 @@ class TestParseOffset:
|
||||
@pytest.mark.parametrize("offset_x, parsed_x, offset_y, parsed_y", [
|
||||
["-5.5%", Scalar(-5.5, Unit.PERCENT, Unit.WIDTH), "-30%", Scalar(-30, Unit.PERCENT, Unit.HEIGHT)],
|
||||
["5%", Scalar(5, Unit.PERCENT, Unit.WIDTH), "40%", Scalar(40, Unit.PERCENT, Unit.HEIGHT)],
|
||||
["10", Scalar(10, Unit.CELLS, Unit.WIDTH), "40", Scalar(40, Unit.CELLS, Unit.HEIGHT)],
|
||||
["-10", Scalar(-10, Unit.CELLS, Unit.WIDTH), "40", Scalar(40, Unit.CELLS, Unit.HEIGHT)],
|
||||
])
|
||||
def test_separate_rules(self, offset_x, parsed_x, offset_y, parsed_y):
|
||||
css = f"""#some-widget {{
|
||||
|
||||
Reference in New Issue
Block a user