changeset 18:72e0d37a853c

Syntax highlight code examples.
author Martin Geisler <>
date Mon, 18 Feb 2008 10:37:21 +0100
parents e1ecb5ef8f94
children 19c203ffac06
files docs/unit-testing.txt
diffstat 1 files changed, 9 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/docs/unit-testing.txt	Mon Feb 18 10:36:57 2008 +0100
+++ b/docs/unit-testing.txt	Mon Feb 18 10:37:21 2008 +0100
@@ -25,7 +25,9 @@
 works correctly in Python. In other words, you must make sure that
 VIFF is installed or that the root of your source tree is in
 ``PYTHONPATH``. You can test this by changing to some unrelated
-directory, starting an interactive Python session and run::
+directory, starting an interactive Python session and run:
+.. sourcecode:: pycon
   >>> import viff
   >>> print viff.__version__
@@ -164,7 +166,9 @@
 A simple example of a unit test is ``viff.test.test_field`` which
-looks like this (heavily abbreviated)::
+looks like this (heavily abbreviated):
+.. sourcecode:: python
   """Tests for viff.field."""
@@ -224,7 +228,9 @@
 number of Runtime instances in this way. All you need to do is to
 create a subclass of RuntimeTestCase and decorate the test methods
 with ``protocol`` like this example (abbreviated from
+.. sourcecode:: python
   from viff.test.util import RuntimeTestCase, protocol