import pytest

@pytest.mark.parametrize(('input', 'expected'), [('3+5', 8), ('2+4', 6), (
    '6*9', 42)])
def test_eval(input, expected):
    assert eval(input) == expected
Is there a Spock-like testing library for Python