summaryrefslogtreecommitdiff
path: root/tests/test_sql.py
diff options
context:
space:
mode:
authorThomas Aglassinger <roskakori@users.sourceforge.net>2016-03-22 22:52:18 +0100
committerThomas Aglassinger <roskakori@users.sourceforge.net>2016-03-22 22:52:18 +0100
commit393de7069e7c6e855d5086c30e41863b8ceb2c1c (patch)
tree08020fa99869137610d812fc95dface3e8c7c5c6 /tests/test_sql.py
parent895d02d4202b0962d3be6a9d06d6da38626e1d95 (diff)
downloadpygments-393de7069e7c6e855d5086c30e41863b8ceb2c1c.tar.gz
Fixed broken test case by properly naming Transact-SQL example file to prevent ResourceLexer from attempting to lex it.
Diffstat (limited to 'tests/test_sql.py')
-rw-r--r--tests/test_sql.py13
1 files changed, 1 insertions, 12 deletions
diff --git a/tests/test_sql.py b/tests/test_sql.py
index 37a81ff8..f4016918 100644
--- a/tests/test_sql.py
+++ b/tests/test_sql.py
@@ -6,12 +6,10 @@
:copyright: Copyright 2006-2016 by the Pygments team, see AUTHORS.
:license: BSD, see LICENSE for details.
"""
-import io
-import os.path
import unittest
from pygments.lexers.sql import TransactSqlLexer
-from pygments.token import Comment, Error, Name, Number, Whitespace
+from pygments.token import Comment, Name, Number, Whitespace
class TransactSqlLexerTest(unittest.TestCase):
@@ -65,12 +63,3 @@ class TransactSqlLexerTest(unittest.TestCase):
(Comment.Multiline, '*/'),
(Comment.Multiline, '*/'),
))
-
- def test_can_lex_example_file(self):
- tests_path = os.path.dirname(__file__)
- example_path = os.path.join(tests_path, 'examplefiles', 'test_transact-sql.txt')
-
- with io.open(example_path, 'r', encoding='utf-8') as example_file:
- example_code = example_file.read()
- for token_type, token_value in self.lexer.get_tokens(example_code):
- self.assertNotEqual(Error, token_type, 'token_value=%r' % token_value)