Enable Ruff rule PT007 (#113764)
Co-authored-by: Franck Nijhof <frenck@frenck.nl>
This commit is contained in:
parent
089a3ab6d7
commit
00ec7f11f0
204 changed files with 908 additions and 921 deletions
|
@ -12,7 +12,7 @@ _LOGGER = logging.getLogger(__name__)
|
|||
|
||||
@pytest.mark.parametrize(
|
||||
"blueprint",
|
||||
(
|
||||
[
|
||||
# Test allow extra
|
||||
{
|
||||
"trigger": "Test allow extra",
|
||||
|
@ -52,7 +52,7 @@ _LOGGER = logging.getLogger(__name__)
|
|||
},
|
||||
}
|
||||
},
|
||||
),
|
||||
],
|
||||
)
|
||||
def test_blueprint_schema(blueprint) -> None:
|
||||
"""Test different schemas."""
|
||||
|
@ -65,7 +65,7 @@ def test_blueprint_schema(blueprint) -> None:
|
|||
|
||||
@pytest.mark.parametrize(
|
||||
"blueprint",
|
||||
(
|
||||
[
|
||||
# no domain
|
||||
{"blueprint": {}},
|
||||
# non existing key in blueprint
|
||||
|
@ -94,7 +94,7 @@ def test_blueprint_schema(blueprint) -> None:
|
|||
},
|
||||
}
|
||||
},
|
||||
),
|
||||
],
|
||||
)
|
||||
def test_blueprint_schema_invalid(blueprint) -> None:
|
||||
"""Test different schemas."""
|
||||
|
@ -104,11 +104,11 @@ def test_blueprint_schema_invalid(blueprint) -> None:
|
|||
|
||||
@pytest.mark.parametrize(
|
||||
"bp_instance",
|
||||
(
|
||||
[
|
||||
{"path": "hello.yaml"},
|
||||
{"path": "hello.yaml", "input": {}},
|
||||
{"path": "hello.yaml", "input": {"hello": None}},
|
||||
),
|
||||
],
|
||||
)
|
||||
def test_blueprint_instance_fields(bp_instance) -> None:
|
||||
"""Test blueprint instance fields."""
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue