From df181d0916f5a37c625ec65be1fb434fda8d25ab Mon Sep 17 00:00:00 2001 From: ~Jhellico Date: Fri, 2 Aug 2024 13:35:41 +0300 Subject: [PATCH 1/3] Add test docs build to CI/CD --- .github/workflows/ci-cd.yml | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index ac9d69435..476176584 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -153,6 +153,30 @@ jobs: python -m pip install `ls dist/*.tar.gz` pytest --dist loadscope --numprocesses auto tests/countries tests/financial + test-docs: + name: Test docs build + runs-on: ubuntu-latest + needs: test + steps: + - name: Checkout Repository + uses: actions/checkout@v4 + + - name: Set Up Python + uses: actions/setup-python@v5 + with: + cache: pip + cache-dependency-path: requirements/docs.txt + python-version: '3.12' + + - name: Install Dependencies + run: | + python -m pip install --upgrade --requirement requirements/docs.txt + python -m pip install . + + - name: Build docs + run: | + python -m sphinx -E -T -W -b html -D language=en -j auto -q docs/source docs/build + publish-pypi-main: name: Publish to PyPI if: | @@ -162,6 +186,7 @@ jobs: environment: main needs: - test-build + - test-docs permissions: id-token: write runs-on: ubuntu-latest From f11400e4b33b97a54ba07216daa329ea3870ca03 Mon Sep 17 00:00:00 2001 From: ~Jhellico Date: Fri, 2 Aug 2024 18:03:50 +0300 Subject: [PATCH 2/3] Fix --- .github/workflows/ci-cd.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index 476176584..f7bc2bd8c 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -170,7 +170,7 @@ jobs: - name: Install Dependencies run: | - python -m pip install --upgrade --requirement requirements/docs.txt + python -m pip install --requirement requirements/docs.txt python -m pip install . - name: Build docs From 61da0bc5353d5a9f3b827f66878d8433f05c4bed Mon Sep 17 00:00:00 2001 From: ~Jhellico Date: Fri, 2 Aug 2024 19:16:11 +0300 Subject: [PATCH 3/3] Use make --- .github/workflows/ci-cd.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index f7bc2bd8c..62c350527 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -175,7 +175,7 @@ jobs: - name: Build docs run: | - python -m sphinx -E -T -W -b html -D language=en -j auto -q docs/source docs/build + make doc publish-pypi-main: name: Publish to PyPI