Skip to content

Commit b7edd9a

Browse files
committed
skip tests on older python
1 parent d926e99 commit b7edd9a

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

tests/test_prettier.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import ast
22
import os
33
import string
4+
import sys
45
from collections import Counter, OrderedDict, namedtuple
56
from dataclasses import dataclass
67
from typing import List
@@ -460,6 +461,7 @@ class User(SQLAlchemyBase):
460461
)
461462

462463

464+
@pytest.mark.skipif(sys.version_info < (3, 9), reason='no indent on older versions')
463465
def test_ast_expr():
464466
assert pformat(ast.parse('print(1, 2, round(3))', mode='eval')) == (
465467
"Expression("
@@ -477,5 +479,6 @@ def test_ast_expr():
477479
)
478480

479481

482+
@pytest.mark.skipif(sys.version_info < (3, 9), reason='no indent on older versions')
480483
def test_ast_module():
481484
assert pformat(ast.parse('print(1, 2, round(3))')).startswith('Module(\n body=[')

0 commit comments

Comments
 (0)