summaryrefslogtreecommitdiffstats
path: root/Doc/library/sets.rst
diff options
context:
space:
mode:
authorGeorg Brandl <georg@python.org>2008-03-22 22:04:10 (GMT)
committerGeorg Brandl <georg@python.org>2008-03-22 22:04:10 (GMT)
commite8f1b00372891ddf6e42886bff397c43dad7a4eb (patch)
treeed62d4d8c7055404bbfbd1382afadd443cce6944 /Doc/library/sets.rst
parent7a45ab826e9b2ecaee49cc8fd206631395a48927 (diff)
downloadcpython-e8f1b00372891ddf6e42886bff397c43dad7a4eb.zip
cpython-e8f1b00372891ddf6e42886bff397c43dad7a4eb.tar.gz
cpython-e8f1b00372891ddf6e42886bff397c43dad7a4eb.tar.bz2
Enable doctest running for several other documents.
We have now over 640 doctests that are run with "make doctest".
Diffstat (limited to 'Doc/library/sets.rst')
-rw-r--r--Doc/library/sets.rst6
1 files changed, 2 insertions, 4 deletions
diff --git a/Doc/library/sets.rst b/Doc/library/sets.rst
index 88e442a..6d974d6 100644
--- a/Doc/library/sets.rst
+++ b/Doc/library/sets.rst
@@ -192,8 +192,6 @@ the builtin :class:`set()` and :class:`frozenset()` types.
Example
-------
-::
-
>>> from sets import Set
>>> engineers = Set(['John', 'Jane', 'Jack', 'Janice'])
>>> programmers = Set(['Jack', 'Sam', 'Susan', 'Janice'])
@@ -202,14 +200,14 @@ Example
>>> engineering_management = engineers & managers # intersection
>>> fulltime_management = managers - engineers - programmers # difference
>>> engineers.add('Marvin') # add element
- >>> print engineers
+ >>> print engineers # doctest: +SKIP
Set(['Jane', 'Marvin', 'Janice', 'John', 'Jack'])
>>> employees.issuperset(engineers) # superset test
False
>>> employees.update(engineers) # update from another set
>>> employees.issuperset(engineers)
True
- >>> for group in [engineers, programmers, managers, employees]:
+ >>> for group in [engineers, programmers, managers, employees]: # doctest: +SKIP
... group.discard('Susan') # unconditionally remove element
... print group
...