We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d53cabc commit 61c69e9Copy full SHA for 61c69e9
1 file changed
test.py
@@ -0,0 +1,15 @@
1
+"""Some extra sanity checks for the CI."""
2
+
3
+import sys
4
+from pathlib import Path
5
6
+NEWS = Path(__file__).parent / "content" / "news"
7
8
+for root, dirs, files in NEWS.walk():
9
+ for name in files:
10
+ f = root / name
11
+ m = re.search(r"^Tags: (?P<tags>.*)$", f.read_text())
12
+ if m and f.parent.name not in m.group("tags"):
13
+ print(f"Tag from path must be repeated in Tags metadata: {f}")
14
+ sys.exit(1)
15
0 commit comments