~nkarageuzian/mailman/bug-1312884

« back to all changes in this revision

Viewing changes to src/mailman/commands/docs/help.rst

  • Committer: Barry Warsaw
  • Date: 2014-04-28 15:23:35 UTC
  • Revision ID: barry@list.org-20140428152335-uomli7adnqf3h6dm
Use print functions consistently through, and update all __future__ imports to
reflect this.

Also, mock out sys.stderr on some tests so that their nose2 output is quieter.

A few other minor coding style consistencies.

Show diffs side-by-side

added added

removed removed

Lines of Context:
8
8
    >>> mlist = create_list('test@example.com')
9
9
    >>> from mailman.commands.eml_help import Help
10
10
    >>> help = Help()
11
 
    >>> print help.name
 
11
    >>> print(help.name)
12
12
    help
13
 
    >>> print help.description
 
13
    >>> print(help.description)
14
14
    Get help about available email commands.
15
 
    >>> print help.argument_description
 
15
    >>> print(help.argument_description)
16
16
    [command]
17
17
 
18
18
With no arguments, `help` provides a list of the available commands and a
23
23
    >>> results = Results()
24
24
 
25
25
    >>> from mailman.email.message import Message
26
 
    >>> print help.process(mlist, Message(), {}, (), results)
 
26
    >>> print(help.process(mlist, Message(), {}, (), results))
27
27
    ContinueProcessing.yes
28
 
    >>> print unicode(results)
 
28
    >>> print(unicode(results))
29
29
    The results of your email command are provided below.
30
30
    <BLANKLINE>
31
31
    confirm     - Confirm a subscription request.
42
42
With an argument, you can get more detailed help about a specific command.
43
43
 
44
44
    >>> results = Results()
45
 
    >>> print help.process(mlist, Message(), {}, ('help',), results)
 
45
    >>> print(help.process(mlist, Message(), {}, ('help',), results))
46
46
    ContinueProcessing.yes
47
 
    >>> print unicode(results)
 
47
    >>> print(unicode(results))
48
48
    The results of your email command are provided below.
49
49
    <BLANKLINE>
50
50
    help [command]
54
54
Some commands have even more detailed help.
55
55
 
56
56
    >>> results = Results()
57
 
    >>> print help.process(mlist, Message(), {}, ('join',), results)
 
57
    >>> print(help.process(mlist, Message(), {}, ('join',), results))
58
58
    ContinueProcessing.yes
59
 
    >>> print unicode(results)
 
59
    >>> print(unicode(results))
60
60
    The results of your email command are provided below.
61
61
    <BLANKLINE>
62
62
    join [digest=<no|mime|plain>]