Skip to content

Commit

Permalink
Prevent pylint errors
Browse files Browse the repository at this point in the history
When running pylint with Python 3.9, it complained about an unsupported
binary operation.
  • Loading branch information
treiher committed Jan 10, 2023
1 parent a080dd6 commit 6ae5fe4
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 32 deletions.
26 changes: 13 additions & 13 deletions tests/property/expression_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,37 +8,37 @@
st.one_of(
strategies.mathematical_expressions(
st.one_of(
strategies.numbers()
| strategies.variables(strategies.identifiers())
| strategies.attributes(strategies.identifiers())
strategies.numbers(),
strategies.variables(strategies.identifiers()),
strategies.attributes(strategies.identifiers()),
)
),
strategies.boolean_relations(
st.one_of(strategies.aggregates(strategies.numbers()) | strategies.strings()),
st.one_of(strategies.aggregates(strategies.numbers()), strategies.strings()),
),
strategies.boolean_expressions(
st.one_of(
strategies.mathematical_expressions(
st.one_of(
strategies.numbers()
| strategies.variables(strategies.identifiers())
| strategies.attributes(strategies.identifiers())
strategies.numbers(),
strategies.variables(strategies.identifiers()),
strategies.attributes(strategies.identifiers()),
)
)
)
),
strategies.calls(
st.one_of(
strategies.numbers()
| strategies.variables(strategies.identifiers())
| strategies.attributes(strategies.identifiers())
strategies.numbers(),
strategies.variables(strategies.identifiers()),
strategies.attributes(strategies.identifiers()),
)
),
strategies.quantified_expressions(
st.one_of(
strategies.numbers()
| strategies.variables(strategies.identifiers())
| strategies.attributes(strategies.identifiers())
strategies.numbers(),
strategies.variables(strategies.identifiers()),
strategies.attributes(strategies.identifiers()),
)
),
strategies.strings(),
Expand Down
38 changes: 19 additions & 19 deletions tests/property/specification_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@
@given(
strategies.mathematical_expressions(
st.one_of(
strategies.numbers()
| strategies.variables(strategies.identifiers())
| strategies.attributes(strategies.identifiers())
strategies.numbers(),
strategies.variables(strategies.identifiers()),
strategies.attributes(strategies.identifiers()),
)
)
)
Expand All @@ -30,9 +30,9 @@ def test_parsing_mathematical_expressions(expression: expr.Expr) -> None:
st.one_of(
strategies.mathematical_expressions(
st.one_of(
strategies.numbers()
| strategies.variables(strategies.identifiers())
| strategies.attributes(strategies.identifiers())
strategies.numbers(),
strategies.variables(strategies.identifiers()),
strategies.attributes(strategies.identifiers()),
)
)
)
Expand All @@ -48,37 +48,37 @@ def test_parsing_boolean_expressions(expression: expr.Expr) -> None:
st.one_of(
strategies.mathematical_expressions(
st.one_of(
strategies.numbers()
| strategies.variables(strategies.identifiers())
| strategies.attributes(strategies.identifiers())
strategies.numbers(),
strategies.variables(strategies.identifiers()),
strategies.attributes(strategies.identifiers()),
)
),
strategies.boolean_relations(
st.one_of(strategies.aggregates(strategies.numbers()) | strategies.strings()),
st.one_of(strategies.aggregates(strategies.numbers()), strategies.strings()),
),
strategies.boolean_expressions(
st.one_of(
strategies.mathematical_expressions(
st.one_of(
strategies.numbers()
| strategies.variables(strategies.identifiers())
| strategies.attributes(strategies.identifiers())
strategies.numbers(),
strategies.variables(strategies.identifiers()),
strategies.attributes(strategies.identifiers()),
)
)
)
),
strategies.calls(
st.one_of(
strategies.numbers()
| strategies.variables(strategies.identifiers())
| strategies.attributes(strategies.identifiers())
strategies.numbers(),
strategies.variables(strategies.identifiers()),
strategies.attributes(strategies.identifiers()),
)
),
strategies.quantified_expressions(
st.one_of(
strategies.numbers()
| strategies.variables(strategies.identifiers())
| strategies.attributes(strategies.identifiers())
strategies.numbers(),
strategies.variables(strategies.identifiers()),
strategies.attributes(strategies.identifiers()),
)
),
strategies.strings(),
Expand Down

0 comments on commit 6ae5fe4

Please sign in to comment.