mirror of
https://github.com/ralsina/tartrazine.git
synced 2025-06-19 06:33:06 -03:00
Reorganize tests into a real spec suite
This commit is contained in:
98
spec/unsupported_lexers/pycon/broken_tb.txt
Normal file
98
spec/unsupported_lexers/pycon/broken_tb.txt
Normal file
@ -0,0 +1,98 @@
|
||||
---input---
|
||||
>>> exec('"')
|
||||
Traceback (most recent call last):
|
||||
File "<stdin>", line 1, in <module>
|
||||
File "<string>", line 1
|
||||
"
|
||||
^
|
||||
SyntaxError: EOL while scanning string literal
|
||||
|
||||
>>> exec('"')
|
||||
Traceback (most recent call last):
|
||||
File "<stdin>", line 1, in <module>
|
||||
File "<string>", line 1, in <module>
|
||||
"
|
||||
^
|
||||
SyntaxError: EOL while scanning string literal
|
||||
|
||||
---tokens---
|
||||
'>>> ' Generic.Prompt
|
||||
'exec' Name
|
||||
'(' Punctuation
|
||||
"'" Literal.String.Single
|
||||
'"' Literal.String.Single
|
||||
"'" Literal.String.Single
|
||||
')' Punctuation
|
||||
'\n' Text.Whitespace
|
||||
|
||||
'Traceback (most recent call last):\n' Generic.Traceback
|
||||
|
||||
' File ' Text
|
||||
'"<stdin>"' Name.Builtin
|
||||
', line ' Text
|
||||
'1' Literal.Number
|
||||
', in ' Text
|
||||
'<module>' Name
|
||||
'\n' Text.Whitespace
|
||||
|
||||
' File ' Text
|
||||
'"<string>"' Name.Builtin
|
||||
', line ' Text
|
||||
'1' Literal.Number
|
||||
'\n' Text.Whitespace
|
||||
|
||||
' ' Text.Whitespace
|
||||
'"' Literal.String.Double
|
||||
'\n' Text.Whitespace
|
||||
|
||||
' ' Text.Whitespace
|
||||
'^' Punctuation.Marker
|
||||
'\n' Text.Whitespace
|
||||
|
||||
'SyntaxError' Generic.Error
|
||||
': ' Text
|
||||
'EOL while scanning string literal' Name
|
||||
'\n' Text.Whitespace
|
||||
|
||||
'\n' Text.Whitespace
|
||||
|
||||
'' Text
|
||||
'>>> ' Generic.Prompt
|
||||
'exec' Name
|
||||
'(' Punctuation
|
||||
"'" Literal.String.Single
|
||||
'"' Literal.String.Single
|
||||
"'" Literal.String.Single
|
||||
')' Punctuation
|
||||
'\n' Text.Whitespace
|
||||
|
||||
'Traceback (most recent call last):\n' Generic.Traceback
|
||||
|
||||
' File ' Text
|
||||
'"<stdin>"' Name.Builtin
|
||||
', line ' Text
|
||||
'1' Literal.Number
|
||||
', in ' Text
|
||||
'<module>' Name
|
||||
'\n' Text.Whitespace
|
||||
|
||||
' File ' Text
|
||||
'"<string>"' Name.Builtin
|
||||
', line ' Text
|
||||
'1' Literal.Number
|
||||
', in ' Text
|
||||
'<module>' Name
|
||||
'\n' Text.Whitespace
|
||||
|
||||
' ' Text.Whitespace
|
||||
'"' Literal.String.Double
|
||||
'\n' Text.Whitespace
|
||||
|
||||
' ' Text.Whitespace
|
||||
'^' Punctuation.Marker
|
||||
'\n' Text.Whitespace
|
||||
|
||||
'SyntaxError' Generic.Error
|
||||
': ' Text
|
||||
'EOL while scanning string literal' Name
|
||||
'\n' Text.Whitespace
|
108
spec/unsupported_lexers/pycon/multiple_tb.txt
Normal file
108
spec/unsupported_lexers/pycon/multiple_tb.txt
Normal file
@ -0,0 +1,108 @@
|
||||
---input---
|
||||
>>> from multiprocessing import Pool
|
||||
>>> p = Pool(5)
|
||||
>>> def f(x):
|
||||
... return x*x
|
||||
...
|
||||
>>> with p:
|
||||
... p.map(f, [1,2,3])
|
||||
Process PoolWorker-1:
|
||||
Process PoolWorker-2:
|
||||
Process PoolWorker-3:
|
||||
Traceback (most recent call last):
|
||||
Traceback (most recent call last):
|
||||
Traceback (most recent call last):
|
||||
AttributeError: Can't get attribute 'f' on <module '__main__' (<class '_frozen_importlib.BuiltinImporter'>)>
|
||||
AttributeError: Can't get attribute 'f' on <module '__main__' (<class '_frozen_importlib.BuiltinImporter'>)>
|
||||
AttributeError: Can't get attribute 'f' on <module '__main__' (<class '_frozen_importlib.BuiltinImporter'>)>
|
||||
|
||||
---tokens---
|
||||
'>>> ' Generic.Prompt
|
||||
'from' Keyword.Namespace
|
||||
' ' Text
|
||||
'multiprocessing' Name.Namespace
|
||||
' ' Text
|
||||
'import' Keyword.Namespace
|
||||
' ' Text
|
||||
'Pool' Name
|
||||
'\n' Text.Whitespace
|
||||
|
||||
'>>> ' Generic.Prompt
|
||||
'p' Name
|
||||
' ' Text
|
||||
'=' Operator
|
||||
' ' Text
|
||||
'Pool' Name
|
||||
'(' Punctuation
|
||||
'5' Literal.Number.Integer
|
||||
')' Punctuation
|
||||
'\n' Text.Whitespace
|
||||
|
||||
'>>> ' Generic.Prompt
|
||||
'def' Keyword
|
||||
' ' Text
|
||||
'f' Name.Function
|
||||
'(' Punctuation
|
||||
'x' Name
|
||||
')' Punctuation
|
||||
':' Punctuation
|
||||
'\n' Text.Whitespace
|
||||
|
||||
'... ' Generic.Prompt
|
||||
' ' Text
|
||||
'return' Keyword
|
||||
' ' Text
|
||||
'x' Name
|
||||
'*' Operator
|
||||
'x' Name
|
||||
'\n' Text.Whitespace
|
||||
|
||||
'...' Generic.Prompt
|
||||
'\n' Text.Whitespace
|
||||
|
||||
'>>> ' Generic.Prompt
|
||||
'with' Keyword
|
||||
' ' Text
|
||||
'p' Name
|
||||
':' Punctuation
|
||||
'\n' Text.Whitespace
|
||||
|
||||
'... ' Generic.Prompt
|
||||
' ' Text
|
||||
'p' Name
|
||||
'.' Operator
|
||||
'map' Name
|
||||
'(' Punctuation
|
||||
'f' Name
|
||||
',' Punctuation
|
||||
' ' Text
|
||||
'[' Punctuation
|
||||
'1' Literal.Number.Integer
|
||||
',' Punctuation
|
||||
'2' Literal.Number.Integer
|
||||
',' Punctuation
|
||||
'3' Literal.Number.Integer
|
||||
']' Punctuation
|
||||
')' Punctuation
|
||||
'\n' Text.Whitespace
|
||||
|
||||
'Process PoolWorker-1:\n' Generic.Output
|
||||
|
||||
'Process PoolWorker-2:\n' Generic.Output
|
||||
|
||||
'Process PoolWorker-3:\n' Generic.Output
|
||||
|
||||
'Traceback (most recent call last):\n' Generic.Traceback
|
||||
|
||||
'Traceback (most recent call last):\n' Generic.Traceback
|
||||
|
||||
'Traceback (most recent call last):\n' Generic.Traceback
|
||||
|
||||
'AttributeError' Generic.Error
|
||||
': ' Text
|
||||
"Can't get attribute 'f' on <module '__main__' (<class '_frozen_importlib.BuiltinImporter'>)>" Name
|
||||
'\n' Text.Whitespace
|
||||
|
||||
"AttributeError: Can't get attribute 'f' on <module '__main__' (<class '_frozen_importlib.BuiltinImporter'>)>\n" Other
|
||||
|
||||
"AttributeError: Can't get attribute 'f' on <module '__main__' (<class '_frozen_importlib.BuiltinImporter'>)>\n" Other
|
17
spec/unsupported_lexers/pycon/unterminated_tb.txt
Normal file
17
spec/unsupported_lexers/pycon/unterminated_tb.txt
Normal file
@ -0,0 +1,17 @@
|
||||
---input---
|
||||
>>> unterminated_traceback()
|
||||
Traceback (most recent call last):
|
||||
>>>
|
||||
|
||||
---tokens---
|
||||
'>>> ' Generic.Prompt
|
||||
'unterminated_traceback' Name
|
||||
'(' Punctuation
|
||||
')' Punctuation
|
||||
'\n' Text.Whitespace
|
||||
|
||||
'Traceback (most recent call last):\n' Generic.Traceback
|
||||
|
||||
'' Text
|
||||
'>>>' Generic.Prompt
|
||||
'\n' Text.Whitespace
|
Reference in New Issue
Block a user