Skip to content

Commit 697da15

Browse files
committed
Make the matrix easier to read
1 parent c386ab0 commit 697da15

1 file changed

Lines changed: 9 additions & 17 deletions

File tree

tests/test_options.py

Lines changed: 9 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1465,25 +1465,17 @@ def cmd(upper):
14651465
("opt_decls", "opt_params", "expect_is_flag", "expect_is_bool_flag"),
14661466
[
14671467
# Not boolean flags.
1468-
pytest.param("-a", {"type": int}, False, False, id="int option"),
1469-
pytest.param("-a", {"type": bool}, False, False, id="bool non-flag [None]"),
1470-
pytest.param("-a", {"default": True}, False, False, id="bool non-flag [True]"),
1471-
pytest.param(
1472-
"-a", {"default": False}, False, False, id="bool non-flag [False]"
1473-
),
1474-
pytest.param("-a", {"flag_value": 1}, True, False, id="non-bool flag_value"),
1468+
("-a", {"type": int}, False, False),
1469+
("-a", {"type": bool}, False, False),
1470+
("-a", {"default": True}, False, False),
1471+
("-a", {"default": False}, False, False),
1472+
("-a", {"flag_value": 1}, True, False),
14751473
# Boolean flags.
1476-
pytest.param("-a", {"is_flag": True}, True, True, id="is_flag=True"),
1477-
pytest.param("-a/-A", {}, True, True, id="secondary option [implicit flag]"),
1478-
pytest.param("-a", {"flag_value": True}, True, True, id="bool flag_value"),
1474+
("-a", {"is_flag": True}, True, True),
1475+
("-a/-A", {}, True, True),
1476+
("-a", {"flag_value": True}, True, True),
14791477
# Non-flag with flag_value.
1480-
pytest.param(
1481-
"-a",
1482-
{"is_flag": False, "flag_value": 1},
1483-
False,
1484-
False,
1485-
id="non-flag with flag_value",
1486-
),
1478+
("-a", {"is_flag": False, "flag_value": 1}, False, False),
14871479
],
14881480
)
14891481
def test_flag_auto_detection(

0 commit comments

Comments
 (0)