Testing the isalnum method
The stdtypes have a number of methods that return a boolean. Such functions are excellent to demonstrate parametrization.
import pytest
@pytest.mark.parametrize("val", ["a", "b", "א", "2"])
def test_isalnum(val):
assert val.isalnum()
@pytest.mark.parametrize("val", ["_", " "])
def test_not_isalnum(val):
assert not val.isalnum()