Show More
@@ -68,12 +68,12 b' class TestAnsi(TestsBase):' | |||
|
68 | 68 | def test_ansi2latex(self): |
|
69 | 69 | """ansi2latex test""" |
|
70 | 70 | correct_outputs = { |
|
71 |
'%s' % (TermColors.Red) : r'\ |
|
|
72 |
'hello%s' % TermColors.Blue: r'hello\ |
|
|
73 |
'he%s%sllo' % (TermColors.Green, TermColors.Cyan) : r'he\green{ |
|
|
74 |
'%shello' % TermColors.Yellow : r'\yellow |
|
|
75 |
'{0}h{0}e{0}l{0}l{0}o{0}'.format(TermColors.White) : r'\ |
|
|
76 |
'hel%slo' % TermColors.Green : r'hel\ |
|
|
71 | '%s' % (TermColors.Red) : r'{\color{red}}', | |
|
72 | 'hello%s' % TermColors.Blue: r'hello{\color{blue}}', | |
|
73 | 'he%s%sllo' % (TermColors.Green, TermColors.Cyan) : r'he{\color{green}}{\color{cyan}llo}', | |
|
74 | '%shello' % TermColors.Yellow : r'{\color{yellow}hello}', | |
|
75 | '{0}h{0}e{0}l{0}l{0}o{0}'.format(TermColors.White) : r'{\color{white}h}{\color{white}e}{\color{white}l}{\color{white}l}{\color{white}o}{\color{white}}', | |
|
76 | 'hel%slo' % TermColors.Green : r'hel{\color{green}lo}', | |
|
77 | 77 | 'hello' : 'hello'} |
|
78 | 78 | |
|
79 | 79 | for inval, outval in correct_outputs.items(): |
@@ -1,6 +1,6 b'' | |||
|
1 | 1 | { |
|
2 | 2 | "metadata": { |
|
3 |
"name": " |
|
|
3 | "name": "" | |
|
4 | 4 | }, |
|
5 | 5 | "nbformat": 3, |
|
6 | 6 | "nbformat_minor": 0, |
@@ -171,12 +171,15 b'' | |||
|
171 | 171 | "prompt_number": 14 |
|
172 | 172 | }, |
|
173 | 173 | { |
|
174 |
"cell_type": " |
|
|
175 | "collapsed": false, | |
|
176 | "input": [], | |
|
177 | "language": "python", | |
|
174 | "cell_type": "markdown", | |
|
178 | 175 | "metadata": {}, |
|
179 |
" |
|
|
176 | "source": [ | |
|
177 | "```python\n", | |
|
178 | "def foo(bar=1):\n", | |
|
179 | " \"\"\"docstring\"\"\"\n", | |
|
180 | " raise Exception(\"message\")\n", | |
|
181 | "```" | |
|
182 | ] | |
|
180 | 183 | } |
|
181 | 184 | ], |
|
182 | 185 | "metadata": {} |
General Comments 0
You need to be logged in to leave comments.
Login now