Skip to content

Commit

Permalink
add test_complete_core_isinstance
Browse files Browse the repository at this point in the history
  • Loading branch information
samuelcolvin committed Aug 2, 2022
1 parent d30d268 commit 1e93886
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions tests/benchmarks/test_complete_benchmark.py
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,17 @@ def f():
raise RuntimeError('expected ValueError')


@pytest.mark.benchmark(group='complete-wrong')
def test_complete_core_isinstance(benchmark):
v = SchemaValidator(schema())
data = input_data_wrong()
assert v.isinstance_python(data) is False

@benchmark
def f():
v.isinstance_python(data)


@skip_pydantic
@pytest.mark.benchmark(group='complete-wrong')
def test_complete_pyd_error(benchmark):
Expand Down

0 comments on commit 1e93886

Please sign in to comment.