summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJon Chappell <jon@jchome.us>2015-04-13 14:07:51 -0400
committerJon Chappell <jon@jchome.us>2015-04-13 14:07:51 -0400
commit96e475bbac00c650dd595961376fe1a78a160208 (patch)
treea3531c233bf4444c6bbf6428b93ee10e5b543f33
parentf6cc3e33810adcdb100a9223971b602bbb46881f (diff)
downloadpython-coveragepy-96e475bbac00c650dd595961376fe1a78a160208.tar.gz
Fix Issue 361, and update tests accordingly.
-rw-r--r--tests/farm/html/run_a.py12
-rw-r--r--tests/farm/html/run_b_branch.py18
-rw-r--r--tests/farm/html/run_bom.py2
-rw-r--r--tests/farm/html/run_isolatin1.py2
-rw-r--r--tests/farm/html/run_other.py4
-rw-r--r--tests/farm/html/run_partial.py12
-rw-r--r--tests/farm/html/run_styled.py14
-rw-r--r--tests/farm/html/run_tabbed.py10
-rw-r--r--tests/farm/html/run_unicode.py6
9 files changed, 40 insertions, 40 deletions
diff --git a/tests/farm/html/run_a.py b/tests/farm/html/run_a.py
index 7963d2e..f510e11 100644
--- a/tests/farm/html/run_a.py
+++ b/tests/farm/html/run_a.py
@@ -13,14 +13,14 @@ runfunc(html_it, rundir="src")
# and check that certain key strings are in the output.
compare("gold_a", "html_a", size_within=10, file_pattern="*.html")
contains("html_a/a_py.html",
- "<span class='key'>if</span> <span class='num'>1</span> <span class='op'>&lt;</span> <span class='num'>2</span>",
- "&nbsp; &nbsp; <span class='nam'>a</span> <span class='op'>=</span> <span class='num'>3</span>",
- "<span class='pc_cov'>67%</span>"
+ '<span class="key">if</span> <span class="num">1</span> <span class="op">&lt;</span> <span class="num">2</span>',
+ '&nbsp; &nbsp; <span class="nam">a</span> <span class="op">=</span> <span class="num">3</span>',
+ '<span class="pc_cov">67%</span>'
)
contains("html_a/index.html",
- "<a href='a_py.html'>a.py</a>",
- "<span class='pc_cov'>67%</span>",
- "<td class='right' data-ratio='2 3'>67%</td>",
+ '<a href="a_py.html">a.py</a>',
+ '<span class="pc_cov">67%</span>',
+ '<td class="right" data-ratio="2 3">67%</td>',
)
clean("html_a")
diff --git a/tests/farm/html/run_b_branch.py b/tests/farm/html/run_b_branch.py
index c92252c..388b5c5 100644
--- a/tests/farm/html/run_b_branch.py
+++ b/tests/farm/html/run_b_branch.py
@@ -13,17 +13,17 @@ runfunc(html_it, rundir="src")
# and check that certain key strings are in the output.
compare("gold_b_branch", "html_b_branch", size_within=10, file_pattern="*.html")
contains("html_b_branch/b_py.html",
- "<span class='key'>if</span> <span class='nam'>x</span> <span class='op'>&lt;</span> <span class='num'>2</span>",
- "&nbsp; &nbsp; <span class='nam'>a</span> <span class='op'>=</span> <span class='num'>3</span>",
- "<span class='pc_cov'>70%</span>",
- "<span class='annotate' title='no jump to this line number'>8</span>",
- "<span class='annotate' title='no jump to this line number'>exit</span>",
- "<span class='annotate' title='no jumps to these line numbers'>23&nbsp;&nbsp; 25</span>",
+ '<span class="key">if</span> <span class="nam">x</span> <span class="op">&lt;</span> <span class="num">2</span>',
+ '&nbsp; &nbsp; <span class="nam">a</span> <span class="op">=</span> <span class="num">3</span>',
+ '<span class="pc_cov">70%</span>',
+ '<span class="annotate" title="no jump to this line number">8</span>',
+ '<span class="annotate" title="no jump to this line number">exit</span>',
+ '<span class="annotate" title="no jumps to these line numbers">23&nbsp;&nbsp; 25</span>',
)
contains("html_b_branch/index.html",
- "<a href='b_py.html'>b.py</a>",
- "<span class='pc_cov'>70%</span>",
- "<td class='right' data-ratio='16 23'>70%</td>",
+ '<a href="b_py.html">b.py</a>',
+ '<span class="pc_cov">70%</span>',
+ '<td class="right" data-ratio="16 23">70%</td>',
)
clean("html_b_branch")
diff --git a/tests/farm/html/run_bom.py b/tests/farm/html/run_bom.py
index 9694975..a6e6d8b 100644
--- a/tests/farm/html/run_bom.py
+++ b/tests/farm/html/run_bom.py
@@ -15,7 +15,7 @@ runfunc(html_it, rundir="src")
# and check that certain key strings are in the output.
compare("gold_bom", "html_bom", size_within=10, file_pattern="*.html")
contains("html_bom/bom_py.html",
- "<span class='str'>&quot;3&#215;4 = 12, &#247;2 = 6&#177;0&quot;</span>",
+ '<span class="str">&quot;3&#215;4 = 12, &#247;2 = 6&#177;0&quot;</span>',
)
clean("html_bom")
diff --git a/tests/farm/html/run_isolatin1.py b/tests/farm/html/run_isolatin1.py
index bf3746d..b03cd25 100644
--- a/tests/farm/html/run_isolatin1.py
+++ b/tests/farm/html/run_isolatin1.py
@@ -15,7 +15,7 @@ runfunc(html_it, rundir="src")
# and check that certain key strings are in the output.
compare("gold_isolatin1", "html_isolatin1", size_within=10, file_pattern="*.html")
contains("html_isolatin1/isolatin1_py.html",
- "<span class='str'>&quot;3&#215;4 = 12, &#247;2 = 6&#177;0&quot;</span>",
+ '<span class="str">&quot;3&#215;4 = 12, &#247;2 = 6&#177;0&quot;</span>',
)
clean("html_isolatin1")
diff --git a/tests/farm/html/run_other.py b/tests/farm/html/run_other.py
index 05efa0f..7c7f344 100644
--- a/tests/farm/html/run_other.py
+++ b/tests/farm/html/run_other.py
@@ -19,8 +19,8 @@ for p in glob.glob("html_other/*_other_py.html"):
# and check that certain key strings are in the output.
compare("gold_other", "html_other", size_within=10, file_pattern="*.html")
contains("html_other/index.html",
- "<a href='here_py.html'>here.py</a>",
- "other_py.html'>", "other.py</a>",
+ '<a href="here_py.html">here.py</a>',
+ 'other_py.html">', 'other.py</a>',
)
clean("html_other")
diff --git a/tests/farm/html/run_partial.py b/tests/farm/html/run_partial.py
index 3879079..7330bb2 100644
--- a/tests/farm/html/run_partial.py
+++ b/tests/farm/html/run_partial.py
@@ -15,17 +15,17 @@ runfunc(html_it, rundir="src")
# and check that certain key strings are in the output.
compare("gold_partial", "html_partial", size_within=10, file_pattern="*.html")
contains("html_partial/partial_py.html",
- "<p id='t5' class='stm run hide_run'>",
- "<p id='t8' class='stm run hide_run'>",
- "<p id='t11' class='stm run hide_run'>",
+ '<p id="t5" class="stm run hide_run">',
+ '<p id="t8" class="stm run hide_run">',
+ '<p id="t11" class="stm run hide_run">',
# The "if 0" and "if 1" statements are optimized away.
- "<p id='t14' class='pln'>",
+ '<p id="t14" class="pln">',
)
contains("html_partial/index.html",
- "<a href='partial_py.html'>partial.py</a>",
+ '<a href="partial_py.html">partial.py</a>',
)
contains("html_partial/index.html",
- "<span class='pc_cov'>100%</span>"
+ '<span class="pc_cov">100%</span>'
)
clean("html_partial")
diff --git a/tests/farm/html/run_styled.py b/tests/farm/html/run_styled.py
index a18096a..ebfbf3b 100644
--- a/tests/farm/html/run_styled.py
+++ b/tests/farm/html/run_styled.py
@@ -14,15 +14,15 @@ runfunc(html_it, rundir="src")
compare("gold_styled", "html_styled", size_within=10, file_pattern="*.html")
compare("gold_styled", "html_styled", size_within=10, file_pattern="*.css")
contains("html_styled/a_py.html",
- "<link rel='stylesheet' href='extra.css' type='text/css'>",
- "<span class='key'>if</span> <span class='num'>1</span> <span class='op'>&lt;</span> <span class='num'>2</span>",
- "&nbsp; &nbsp; <span class='nam'>a</span> <span class='op'>=</span> <span class='num'>3</span>",
- "<span class='pc_cov'>67%</span>"
+ '<link rel="stylesheet" href="extra.css" type="text/css">',
+ '<span class="key">if</span> <span class="num">1</span> <span class="op">&lt;</span> <span class="num">2</span>',
+ '&nbsp; &nbsp; <span class="nam">a</span> <span class="op">=</span> <span class="num">3</span>',
+ '<span class="pc_cov">67%</span>'
)
contains("html_styled/index.html",
- "<link rel='stylesheet' href='extra.css' type='text/css'>",
- "<a href='a_py.html'>a.py</a>",
- "<span class='pc_cov'>67%</span>"
+ '<link rel="stylesheet" href="extra.css" type="text/css">',
+ '<a href="a_py.html">a.py</a>',
+ '<span class="pc_cov">67%</span>'
)
clean("html_styled")
diff --git a/tests/farm/html/run_tabbed.py b/tests/farm/html/run_tabbed.py
index 679db2e..3e8a900 100644
--- a/tests/farm/html/run_tabbed.py
+++ b/tests/farm/html/run_tabbed.py
@@ -13,11 +13,11 @@ runfunc(html_it, rundir="src")
contains("src/tabbed.py", "\tif x:\t\t\t\t\t# look nice")
contains("html_tabbed/tabbed_py.html",
- ">&nbsp; &nbsp; &nbsp; &nbsp; <span class='key'>if</span> "
- "<span class='nam'>x</span><span class='op'>:</span>"
- "&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; "
- "&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp; "
- "<span class='com'># look nice</span>"
+ '>&nbsp; &nbsp; &nbsp; &nbsp; <span class="key">if</span> '
+ '<span class="nam">x</span><span class="op">:</span>'
+ '&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; '
+ '&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp; '
+ '<span class="com"># look nice</span>'
)
doesnt_contain("html_tabbed/tabbed_py.html", "\t")
diff --git a/tests/farm/html/run_unicode.py b/tests/farm/html/run_unicode.py
index ba34f63..455d016 100644
--- a/tests/farm/html/run_unicode.py
+++ b/tests/farm/html/run_unicode.py
@@ -13,12 +13,12 @@ runfunc(html_it, rundir="src")
# and check that certain key strings are in the output.
compare("gold_unicode", "html_unicode", size_within=10, file_pattern="*.html")
contains("html_unicode/unicode_py.html",
- "<span class='str'>&quot;&#654;d&#729;&#477;b&#592;&#633;&#477;&#652;o&#596;&quot;</span>",
+ '<span class="str">&quot;&#654;d&#729;&#477;b&#592;&#633;&#477;&#652;o&#596;&quot;</span>',
)
contains_any("html_unicode/unicode_py.html",
- "<span class='str'>&quot;db40,dd00: x&#56128;&#56576;&quot;</span>",
- "<span class='str'>&quot;db40,dd00: x&#917760;&quot;</span>",
+ '<span class="str">&quot;db40,dd00: x&#56128;&#56576;&quot;</span>',
+ '<span class="str">&quot;db40,dd00: x&#917760;&quot;</span>',
)
clean("html_unicode")