summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNed Batchelder <ned@nedbatchelder.com>2023-04-01 08:47:26 -0400
committerNed Batchelder <ned@nedbatchelder.com>2023-04-01 08:59:23 -0400
commitacd1e0310b32deb55cff221da172ce91c70c8794 (patch)
treeee4b206b3d16d95b92bba35ec6cabb9f9b6d9d68
parentb8498bf9c144344fd70cbb6e72c13e65c13b5e48 (diff)
downloadpython-coveragepy-git-acd1e0310b32deb55cff221da172ce91c70c8794.tar.gz
docs: more tweaking of the gold-file instructions
-rw-r--r--tests/gold/README.rst24
1 files changed, 19 insertions, 5 deletions
diff --git a/tests/gold/README.rst b/tests/gold/README.rst
index ec408182..c90c9eec 100644
--- a/tests/gold/README.rst
+++ b/tests/gold/README.rst
@@ -12,9 +12,22 @@ current output of the tests into the gold files. When a test fails, the actual
output is in the tests/actual directory. Those files are ignored by git.
There's a Makefile in the html directory for working with gold files and their
-associated support files. If actual outputs have changed so that comparisons
-are failing, but the new output is correct, you can use "make update-gold" to
-copy the actual output as the new gold files.
+associated support files.
+
+To view the tests/actual files, you need to tentatively copy them to the gold
+directories, and then add the supporting files so they can be viewed as
+complete output. For example::
+
+ cp tests/actual/html/contexts/* tests/gold/html/contexts
+ cd tests/actual/html
+ make complete
+
+If the new actual output is correct, you can use "make update-gold" to copy the
+actual output as the new gold files.
+
+If you have changed some of the supporting files (.css or .js), then "make
+update-support" will copy the updated files to the tests/gold/html/support
+directory for checking test output.
If you have added a gold test, you'll need to manually copy the tests/actual
files to tests/gold.
@@ -27,8 +40,9 @@ again, you can run just the failed tests again with::
The saved HTML files in the html directories can't be viewed properly without
the supporting CSS and Javascript files. But we don't want to save copies of
those files in every subdirectory. The make target "make complete" in
-tests/gold/html will copy the support file so you can open the HTML files to
-see how they look.
+tests/gold/html will copy the support files so you can open the HTML files to
+see how they look. When you are done checking the output, you can use "make
+clean" to remove the support files from the gold directories.
If the output files are correct, you can update the gold files with "make
update-gold". If there are version-specific gold files (for example,