From 4e84c24fffaa56a2b02a28d7ea866336919cfc82 Mon Sep 17 00:00:00 2001 From: "lina.wolf" Date: Tue, 1 Oct 2024 19:18:53 +0200 Subject: [PATCH] [TASK] Use --minimal-test CLI option for documentation tests (#547) This allows us to control specific settings needed for mininmal tests (like setting only a single output format) or more for the future. See also: https://github.com/TYPO3-Documentation/render-guides/pull/765 Releases: main, 12.4, 11.5 (cherry picked from commit 6ae38ac26c4f03160060024e4cad0cf11ee6bee1) --- .github/workflows/documentation.yml | 17 +++++++++++++++++ Makefile | 3 +-- 2 files changed, 18 insertions(+), 2 deletions(-) create mode 100644 .github/workflows/documentation.yml diff --git a/.github/workflows/documentation.yml b/.github/workflows/documentation.yml new file mode 100644 index 00000000..10cc6d5f --- /dev/null +++ b/.github/workflows/documentation.yml @@ -0,0 +1,17 @@ +name: test documentation + +on: [ push, pull_request ] + +jobs: + tests: + name: documentation + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Test if the documentation will render without warnings + run: | + mkdir -p Documentation-GENERATED-temp \ + && docker run --rm --pull always -v $(pwd):/project \ + ghcr.io/typo3-documentation/render-guides:latest --config=Documentation --no-progress --minimal-test diff --git a/Makefile b/Makefile index 55d66f38..a32d86c0 100644 --- a/Makefile +++ b/Makefile @@ -3,7 +3,6 @@ help: ## Displays this list of targets with descriptions @echo "The following commands are available:\n" @grep -E '^[a-zA-Z0-9_-]+:.*?## .*$$' $(MAKEFILE_LIST) | sort | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[32m%-30s\033[0m %s\n", $$1, $$2}' - .PHONY: docs docs: ## Generate projects docs (from "Documentation" directory) mkdir -p Documentation-GENERATED-temp @@ -14,4 +13,4 @@ docs: ## Generate projects docs (from "Documentation" directory) test-docs: ## Test the documentation rendering mkdir -p Documentation-GENERATED-temp - docker run --rm --pull always -v "$(shell pwd)":/project -t ghcr.io/typo3-documentation/render-guides:latest --config=Documentation --no-progress --fail-on-log --output-format=html + docker run --rm --pull always -v "$(shell pwd)":/project -t ghcr.io/typo3-documentation/render-guides:latest --config=Documentation --no-progress --minimal-test