|
1 | 1 | from __future__ import annotations |
2 | 2 |
|
3 | 3 | from pathlib import Path |
4 | | -from xml.etree import ElementTree |
| 4 | +from xml.etree import ElementTree # nosec B405 |
5 | 5 |
|
6 | 6 | ROOT = Path(__file__).resolve().parents[1] |
7 | 7 |
|
@@ -35,8 +35,13 @@ def test_alpha_template_has_separate_identity_and_storage() -> None: |
35 | 35 | assert ( # nosec B101 |
36 | 36 | alpha.findtext("Repository") == "jsonbored/sure-aio-alpha:latest-alpha" |
37 | 37 | ) |
38 | | - assert alpha.findtext("Registry") == "https://hub.docker.com/r/jsonbored/sure-aio-alpha" # nosec B101 |
39 | | - assert alpha.findtext("TemplateURL", "").endswith("/sure-aio-alpha.xml") # nosec B101 |
| 38 | + assert ( # nosec B101 |
| 39 | + alpha.findtext("Registry") |
| 40 | + == "https://hub.docker.com/r/jsonbored/sure-aio-alpha" |
| 41 | + ) |
| 42 | + assert alpha.findtext("TemplateURL", "").endswith( # nosec B101 |
| 43 | + "/sure-aio-alpha.xml" |
| 44 | + ) |
40 | 45 | assert stable.findtext("Beta") is None # nosec B101 |
41 | 46 | assert alpha.findtext("Beta") == "True" # nosec B101 |
42 | 47 | assert _host_paths(stable).isdisjoint(_host_paths(alpha)) # nosec B101 |
@@ -64,14 +69,15 @@ def test_alpha_template_exposes_upstream_alpha_webauthn_controls() -> None: |
64 | 69 | assert "WEBAUTHN_RP_ID" not in stable_targets # nosec B101 |
65 | 70 | assert "WEBAUTHN_ALLOWED_ORIGINS" not in stable_targets # nosec B101 |
66 | 71 | assert alpha_targets["WEBAUTHN_RP_ID"].get("Display") == "advanced" # nosec B101 |
67 | | - assert alpha_targets["WEBAUTHN_ALLOWED_ORIGINS"].get("Display") == "advanced" # nosec B101 |
| 72 | + assert ( # nosec B101 |
| 73 | + alpha_targets["WEBAUTHN_ALLOWED_ORIGINS"].get("Display") == "advanced" |
| 74 | + ) |
68 | 75 |
|
69 | 76 |
|
70 | 77 | def test_alpha_overlay_is_documented_and_copied() -> None: |
71 | 78 | dockerfile = (ROOT / "Dockerfile.alpha").read_text() |
72 | 79 | initializer = ( |
73 | | - ROOT |
74 | | - / "rootfs-alpha/rails/config/initializers/sure_aio_alpha_import_limits.rb" |
| 80 | + ROOT / "rootfs-alpha/rails/config/initializers/sure_aio_alpha_import_limits.rb" |
75 | 81 | ) |
76 | 82 | ledger = (ROOT / "docs/alpha-lane.md").read_text() |
77 | 83 |
|
|
0 commit comments