Skip to content

Commit

Permalink
do not rely on rst parser only
Browse files Browse the repository at this point in the history
  • Loading branch information
mvorisek committed Jul 17, 2023
1 parent bd2d2e3 commit e4bf98b
Show file tree
Hide file tree
Showing 6 changed files with 13 additions and 3 deletions.
2 changes: 2 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ jobs:
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
pip install -r test/unit/requirements.txt
pip install .
- name: Build Test
Expand Down Expand Up @@ -66,6 +67,7 @@ jobs:
git add . -N && git diff --exit-code
- name: Push Unit Changes
if: failure()
uses: stefanzweifel/git-auto-commit-action@v4
with:
branch: ${{ github.head_ref || github.ref_name }}.changes
Expand Down
6 changes: 3 additions & 3 deletions test/unit/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,14 @@

extensions = [
'sphinxcontrib.phpdomain',
'myst_parser',
]

source_suffix = '.rst'
myst_enable_extensions = ['colon_fence']

source_suffix = '.rst'
master_doc = 'index'

exclude_patterns = ['_build']

pygments_style = 'sphinx'

html_theme = 'default'
2 changes: 2 additions & 0 deletions test/unit/index.rst → test/unit/index.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
```{eval-rst}
Test: Build all files
=====================
.. toctree::
:glob:
**
```
2 changes: 2 additions & 0 deletions test/unit/method.rst → test/unit/method.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
```{eval-rst}
.. php:method:: Foo::simplify()
Simplify expression.
:param array $args: Associative array
```
2 changes: 2 additions & 0 deletions test/unit/ns.rst → test/unit/ns.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
```{eval-rst}
Simple NS
=========
Expand Down Expand Up @@ -61,3 +62,4 @@ Cross linking::
- :php:meth:`X2::simplify`
- :php:meth:`A2::simplify`
```
2 changes: 2 additions & 0 deletions test/unit/requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
sphinx
myst-parser

0 comments on commit e4bf98b

Please sign in to comment.