Skip to content

Commit

Permalink
v2.1.3
Browse files Browse the repository at this point in the history
--------
2023-07-21:
    - require minimum python 3.8
    - remove python 3.7 tests
    - introduce PEP517 packaging standard
    - introduce pyproject.toml build-system
    - remove mypy.ini
    - remove pytest.ini
    - remove setup.cfg
    - remove setup.py
    - remove .bettercodehub.yml
    - remove .travis.yml
    - update black config
    - clean ./tests/test_cli.py
    - add codeql badge
    - move 3rd_party_stubs outside the src directory to ``./.3rd_party_stubs``
    - add pypy 3.10 tests
    - add python 3.12-dev tests
  • Loading branch information
bitranox committed Jul 21, 2023
1 parent c4dc5e4 commit cedf88b
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions rst_include/libs/lib_block_options.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,9 +59,9 @@ def get_option_value_from_block(option: str, block: Block) -> str:
>>> my_block = lib_test.get_test_block_ok()
>>> get_option_value_from_block('code', my_block)
'python'
>>> get_option_value_from_block('encoding', block)
>>> get_option_value_from_block('encoding', my_block)
'utf-8'
>>> get_option_value_from_block('no-option', block)
>>> get_option_value_from_block('no-option', my_block)
Traceback (most recent call last):
...
ValueError: Error in File: ".../README.template.rst", option "no-option" not found in block starting with Line: 47100
Expand All @@ -86,7 +86,7 @@ def is_option_in_block(option: str, block: Block) -> bool:
>>> my_block = lib_test.get_test_block_ok()
>>> is_option_in_block('code', my_block)
True
>>> is_option_in_block('no-option', block)
>>> is_option_in_block('no-option', my_block)
False
"""
Expand All @@ -103,9 +103,9 @@ def get_source_line_number_for_option(option: str, block: Block) -> int:
>>> my_block = lib_test.get_test_block_ok()
>>> get_source_line_number_for_option('code', my_block)
47101
>>> get_source_line_number_for_option('encoding', block)
>>> get_source_line_number_for_option('encoding', my_block)
47102
>>> get_source_line_number_for_option('no-option', block)
>>> get_source_line_number_for_option('no-option', my_block)
Traceback (most recent call last):
...
ValueError: Error in File: ".../README.template.rst", option "no-option" not found in block starting with Line: 47100
Expand All @@ -124,7 +124,7 @@ def is_option_in_source_line(source_line: SourceLine, option: str) -> bool:
>>> my_source_line = lib_classes.SourceLine(line_number=4711, content=' :code:')
>>> is_option_in_source_line(my_source_line, 'code')
True
>>> is_option_in_source_line(source_line, 'encoding')
>>> is_option_in_source_line(my_source_line, 'encoding')
False
"""
Expand Down

0 comments on commit cedf88b

Please sign in to comment.