Remove unused `app fixture passed to test_util_rst` tests (#12840)

This commit is contained in:
Adam Dangoor authored and GitHub committed 2024-08-31 08:12:16 +01:00
1 parent c00388f509
commit 6a07bfcb78
1 file changed
+7 -15
+7 -15
View File
@@ -1,6 +1,5 @@
"""Tests sphinx.util.rst functions."""
import pytest
from docutils.statemachine import StringList
from jinja2 import Environment
@@ -14,8 +13,7 @@ def test_escape():
assert escape('.. toctree::') == r'\.. toctree\:\:'
@pytest.mark.sphinx('html', testroot='root')
def test_append_epilog(app):
def test_append_epilog():
epilog = 'this is rst_epilog\ngood-bye reST!'
content = StringList(
['hello Sphinx world', 'Sphinx is a document generator'],
@@ -32,8 +30,7 @@ def test_append_epilog(app):
]
@pytest.mark.sphinx('html', testroot='root')
def test_prepend_prolog(app):
def test_prepend_prolog():
prolog = 'this is rst_prolog\nhello reST!'
content = StringList(
[
@@ -60,8 +57,7 @@ def test_prepend_prolog(app):
]
@pytest.mark.sphinx('html', testroot='root')
def test_prepend_prolog_with_CR(app):
def test_prepend_prolog_with_CR():
# prolog having CR at tail
prolog = 'this is rst_prolog\nhello reST!\n'
content = StringList(
@@ -79,8 +75,7 @@ def test_prepend_prolog_with_CR(app):
]
@pytest.mark.sphinx('html', testroot='root')
def test_prepend_prolog_without_CR(app):
def test_prepend_prolog_without_CR():
# prolog not having CR at tail
prolog = 'this is rst_prolog\nhello reST!'
content = StringList(
@@ -98,8 +93,7 @@ def test_prepend_prolog_without_CR(app):
]
@pytest.mark.sphinx('html', testroot='root')
def test_prepend_prolog_with_roles_in_sections(app):
def test_prepend_prolog_with_roles_in_sections():
prolog = 'this is rst_prolog\nhello reST!'
content = StringList(
[
@@ -130,8 +124,7 @@ def test_prepend_prolog_with_roles_in_sections(app):
]
@pytest.mark.sphinx('html', testroot='root')
def test_prepend_prolog_with_roles_in_sections_with_newline(app):
def test_prepend_prolog_with_roles_in_sections_with_newline():
# prologue with trailing line break
prolog = 'this is rst_prolog\nhello reST!\n'
content = StringList([':mod:`foo`', '-' * 10, '', 'hello'], 'dummy.rst')
@@ -148,8 +141,7 @@ def test_prepend_prolog_with_roles_in_sections_with_newline(app):
]
@pytest.mark.sphinx('html', testroot='root')
def test_prepend_prolog_with_roles_in_sections_without_newline(app):
def test_prepend_prolog_with_roles_in_sections_without_newline():
# prologue with no trailing line break
prolog = 'this is rst_prolog\nhello reST!'
content = StringList([':mod:`foo`', '-' * 10, '', 'hello'], 'dummy.rst')