Install & Compatibility
Where this runs
tested against v1.8.0 · pip install
no network on importno background threads
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
muslpy 3.10–3.95 runs
installs and imports cleanly · install 0.0s · import 0.152s · 17.8MB
glibcpy 3.10–3.95 runs
installs and imports cleanly · install 1.6s · import 0.128s · 18MB
16MB installed
● package 16MB
Code
Verified usage
Verified import paths — ran on the pinned version, not inferred.
parametrize
✓ from unittest_parametrize import parametrize
✗ from unittest.parametrize import parametrize
unittest_parametrize is a separate package, not part of stdlib unittest.
parametrize
✓ from unittest_parametrize import parametrize
✗ from parametrize import parametrize
Package name is unittest-parametrize but import uses underscores.
Basic parametrization of a test method with multiple sets of arguments.
from unittest import TestCase
from unittest_parametrize import parametrize
class MyTest(TestCase):
@parametrize(
('a', 'b', 'expected'),
[
(1, 2, 3),
(4, 5, 9),
],
)
def test_add(self, a, b, expected):
self.assertEqual(a + b, expected)
Errors
Common errors & fixes
ModuleNotFoundError: No module named 'unittest_parametrize'
Package not installed or misspelled import.
fixInstall with 'pip install unittest-parametrize' and import as 'from unittest_parametrize import parametrize'.
TypeError: 'parametrize' object is not callable
Importing the wrong symbol, e.g., from unittest.parametrize import parametrize.
fixUse correct import: 'from unittest_parametrize import parametrize'.
Upgrade
Version history
1.8.0latest on PyPI · released Sep 9, 2025
Audit
Dependencies
No dependency data recorded yet.