Commit Graph
210 Commits
Author SHA1 Message Date
kevinveenbirkenbachandClaude Opus 4.7 9c8cc1ddcb test(utils/fs): cache project file walks + contents across test run
Adds tests/utils/fs.py with process-level @lru_cache for both the
project-wide os.walk and per-file read_text(), then migrates 26 tests
(24 modified + 2 new) that previously re-walked/re-read the tree
independently to share one cached pass.

Headline win: tests/integration/jinja/test_variable_usage.py drops from
~26s to ~1.3s (≈19x), jinja cluster as a whole ~14x. Other migrated
tests benefit from the shared content cache when the same file is read
by multiple scans in one pytest run.

Non-caching logic changes (kept intentionally):
- test_variable_usage.py: added `if varname not in content: continue`
  fast-path before the line loop (pure short-circuit, identical result).
- test_test_file_naming.py: exempt tests/utils/ from the test_*.py
  prefix rule so the new shared helpers don't trip the lint.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-04-23 20:29:54 +02:00
kevinveenbirkenbachandClaude Opus 4.7 1e085de616 test(lint): drop git subprocess from test-location check
Replace `git ls-files` with an inline `.gitignore` parser + `rglob` walk so
the lint runs inside the `make exec` container where `.git/` isn't mounted.
The matcher covers the pattern shapes used in this repo's `.gitignore`
(bare basenames, `prefix/*`, `*.ext`, path-qualified exact matches).

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-04-22 02:12:02 +02:00
kevinveenbirkenbachandClaude Opus 4.7 b67b392210 test(lint): enforce test_*.py files live under tests/
Adds a repository lint that walks `git ls-files -co --exclude-standard`
and fails if any `test_*.py` lives outside the top-level `tests/` dir,
so .gitignored artefacts stay excluded. Moves the existing decidim role
test into `tests/unit/roles/web-app-decidim/` and rewrites it as
`unittest.TestCase` so `unittest discover` actually executes it.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-04-22 00:54:36 +02:00
kevinveenbirkenbachandClaude Opus 4.7 13d2c0f597 test(lint/todo): suppress warnings when open.project link present
Loosens the Open Project URL matcher to any `https://open.project.infinito.nexus/…`
and applies the same linked-item suppression to inline TODO markers that
already applied to TODO.md list items.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-04-21 13:51:22 +02:00
kevinveenbirkenbachandClaude Opus 4.7 02da33b0a5 refactor(tests): reorganize into topical sub-clusters and consolidate linting
Under tests/integration/roles/ introduce four sub-clusters (meta/,
dependencies/, applications/, run_once/) plus nested dependencies/run_after/
and applications/id/. Fold tests/integration/application_id/ into
roles/applications/id/ and tests/integration/run_once/ into roles/run_once/.
Pull four application-related tests out of tests/integration/ into
roles/applications/, and test_run_after_references.py into the run_after/
sub-cluster.

Consolidate tests/integration/linting/ into tests/lint/{ansible,filesystem,
repository}/, so repository-wide lint checks now run under make test-lint
rather than make test-integration.

Each new cluster ships a README.md and __init__.py; cross-referencing
READMEs (categories, ports, services, roles, applications) are updated to
point at the new paths. Path depths inside moved tests and one hardcoded
ignore path in test_domain.py are adjusted accordingly. No behavior change;
all 32 lint tests and every moved cluster pass locally.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-04-21 12:22:33 +02:00
kevinveenbirkenbachandClaude Opus 4.7 34d6121293 refactor(utils): move config_utils to utils.applications.config, rename resolve_app_config -> get
Consolidates application-config helpers under utils/applications/ with a
concise public API (config.get). Updates all plugin, role, and test
imports; removes the legacy get_app_conf filter and its tests.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-04-19 18:32:30 +02:00
kevinveenbirkenbachandClaude Opus 4.7 faf73471fa chore(claude): tighten gh permission rules and lint settings.json sort order
Consolidate gh ask/deny entries via namespace-wildcard patterns, cover
compound subcommands (item-*, field-*, mark-template*), and add a lint
test that enforces ASCII-sorted permission and sandbox arrays in
.claude/settings.json.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-04-16 21:41:48 +02:00
Environment Test fb7c581a83 refactor(nextcloud): migrate get_app_conf to lookup('config', ...)
Replace legacy filter with the canonical lookup plugin across
nextcloud config, group_vars, dashboard template, and vars
template. Switches Talk TURN from onboard to standalone coturn
by default; gates talk container on spreed plugin flag.

Adds lint test to catch remaining get_app_conf usages.
2026-04-13 15:17:34 +02:00
Environment TestandClaude Sonnet 4.6 0b8e16a45d test(lint): add markdown link checker and fix all broken links
Add tests/lint/repository/test_markdown_links.py — a hard-fail lint
test that scans all git-tracked markdown files for broken relative and
repo-root-absolute links. Skips external URLs, anchor-only links, fenced
code blocks, and placeholder targets.

Apply documentation.md rules to all staged files: add emojis after
headlines in docs files, remove emojis from role README headings,
standardize Credits sections to the canonical format, remove empty
sections and orphaned sentences referring to missing documentation files,
fix raw URLs and incorrect link text across role READMEs and docs.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-10 22:00:46 +02:00
Environment TestandClaude Sonnet 4.6 bf8c535988 feat(update): add docker image version updater CLI, workflow, and lint tests
- Add utils/docker/version_updater.py with CLI for updating Docker image versions
- Add cli/fix/docker_image_versions module wrapping the updater
- Add .github/workflows/update.yml replacing update-skills.yml
- Add scripts/github/ helpers: check_git_changes, install_update_python, open_update_pr, update_docker_image_versions
- Add tests/lint/filesystem/ for scripts/ and utils/ folder file-type enforcement
- Add tests/lint/ansible/ for legacy module usage and vars usage checks
- Reorganize tests/lint/repository/ and move test_vars_usage_in_yaml.py to ansible/
- Add artefact docs: files/github/workflow.md, scripst.md, utils.md
- Apply documentation.md standards to all modified markdown files

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-10 18:38:39 +02:00