Skip to content

Commit 7048c35

Browse files
committed
ignoring the test for python2
1 parent 8bb411f commit 7048c35

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

test/__init__.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
11
# Copyright 2017 Palantir Technologies, Inc.
2+
import sys
23
import pytest
34
from pyls import IS_WIN
45

6+
IS_PY3 = sys.version_info.major == 3
7+
58
unix_only = pytest.mark.skipif(IS_WIN, reason="Unix only")
69
windows_only = pytest.mark.skipif(not IS_WIN, reason="Windows only")
10+
py3_only = pytest.mark.skipif(not IS_PY3, reason="Python3 only")

test/plugins/test_pylint_lint.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
import os
44
import tempfile
55

6+
from test import py3_only
67
from pyls import lsp, uris
78
from pyls.workspace import Document
89
from pyls.plugins import pylint_lint
@@ -49,6 +50,7 @@ def test_pylint(config):
4950
assert unused_import['severity'] == lsp.DiagnosticSeverity.Warning
5051

5152

53+
@py3_only
5254
def test_syntax_error_pylint(config):
5355
with temp_document(DOC_SYNTAX_ERR) as doc:
5456
diag = pylint_lint.pyls_lint(config, doc, True)[0]

0 commit comments

Comments
 (0)