We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent a897051 commit ff73e0bCopy full SHA for ff73e0b
1 file changed
tests/test_pyproject.py
@@ -0,0 +1,24 @@
1
+# License: MIT
2
+# Copyright © 2023 Frequenz Energy-as-a-Service GmbH
3
+
4
+"""Tests for the pyproject.toml file."""
5
6
+import tomllib
7
8
+from frequenz.repo.config import RepositoryType
9
10
+from . import utils
11
12
13
+def test_optional_dependencies() -> None:
14
+ """Test that all repository types handled match the defined in RepositoryType."""
15
+ expected = {t.value for t in RepositoryType}
16
17
+ with open("pyproject.toml", "rb") as pyproject_file:
18
+ pyproject_toml = tomllib.load(pyproject_file)
19
+ defined = {
20
+ k
21
+ for k in pyproject_toml["project"]["optional-dependencies"].keys()
22
+ if k != "dev" and not k.startswith("dev-")
23
+ }
24
+ assert defined == expected, utils.MSG_UNEXPECTED_REPO_TYPES
0 commit comments