summaryrefslogtreecommitdiff
path: root/test/farm/html/run_a.py
diff options
context:
space:
mode:
authorNed Batchelder <ned@nedbatchelder.com>2009-11-25 09:51:51 -0500
committerNed Batchelder <ned@nedbatchelder.com>2009-11-25 09:51:51 -0500
commit0ecc4917ff57918eefb7a90e163fd4bfa9b923d4 (patch)
treebcf7c78fdc4ff6fdacb5de7260cbdb95f3896406 /test/farm/html/run_a.py
parent19cf94d2af6f79cb5995f124bce3fe213823dac0 (diff)
downloadpython-coveragepy-git-0ecc4917ff57918eefb7a90e163fd4bfa9b923d4.tar.gz
Move the javascript code for click-to-sort columns into its own file. It helps keep the HTML tests from changing when the code changes. Also, don't compare non-HTML files in the tests.
Diffstat (limited to 'test/farm/html/run_a.py')
-rw-r--r--test/farm/html/run_a.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/test/farm/html/run_a.py b/test/farm/html/run_a.py
index dc7719a2..047d8982 100644
--- a/test/farm/html/run_a.py
+++ b/test/farm/html/run_a.py
@@ -5,21 +5,21 @@ def html_it():
cov.start()
import a
cov.stop()
- cov.html_report(a, directory="../html")
+ cov.html_report(a, directory="../html_a")
runfunc(html_it, rundir="src")
# HTML files will change often. Check that the sizes are reasonable,
# and check that certain key strings are in the output.
-compare("gold_a", "html", size_within=10)
-contains("html/a.html",
+compare("gold_a", "html_a", size_within=10, file_pattern="*.html")
+contains("html_a/a.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>"
)
-contains("html/index.html",
+contains("html_a/index.html",
"<a href='a.html'>a</a>",
"<span class='pc_cov'>67%</span>"
)
-clean("html")
+clean("html_a")