Switch tox.ini to dependency groups
diff --git a/tox.ini b/tox.ini
index 6e08504..dcde590 100644
--- a/tox.ini
+++ b/tox.ini
@@ -1,5 +1,5 @@
 [tox]
-min_version = 4.0
+min_version = 4.22
 env_list = unitest,type,dictionaries
 
 [testenv:dictionaries]
@@ -10,10 +10,10 @@
 
 [testenv:unitest]
 description = run unit tests
-extras = dev
+dependency_groups = dev
 commands = pytest --cov=codespell_lib codespell_lib
 
 [testenv:type]
 description = run type checks
-extras = types
+dependency_groups = types
 commands = mypy codespell_lib