Skip to content

Commit 617b483

Browse files
committed
Enhance docs related to config. Includes writing docstring for __init__.
1 parent b82669a commit 617b483

File tree

2 files changed

+15
-2
lines changed

2 files changed

+15
-2
lines changed

README.rst

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -79,11 +79,12 @@ Configuration
7979
The remote server accepts following configuration parameters:
8080

8181
============== ================ ========================================
82-
Argument Default Explanation
82+
Argument Default value Explanation
8383
============== ================ ========================================
84+
``library`` Test library instance or module to host. Mandatory argument.
8485
``host`` ``'127.0.0.1'`` Address to listen. Use ``'0.0.0.0'`` to listen to all available interfaces.
8586
``port`` ``8270`` Port to listen. Use ``0`` to select a free port automatically.
86-
``port_file`` ``None`` File to write port that is used.
87+
``port_file`` ``None`` File to write port that is used. ``None`` means file is not written.
8788
``allow_stop`` ``True`` Allow/disallow stopping the server using ``Stop Remote Server`` keyword.
8889
============== ================ ========================================
8990

src/robotremoteserver.py

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,18 @@ class RobotRemoteServer(SimpleXMLRPCServer):
4444

4545
def __init__(self, library, host='127.0.0.1', port=8270, port_file=None,
4646
allow_stop=True):
47+
"""Configure and start-up remote server.
48+
49+
:param library: Test library instance or module to host.
50+
:param host: Address to listen. Use ``'0.0.0.0'`` to listen
51+
to all available interfaces.
52+
:param port: Port to listen. Use ``0`` to select a free port
53+
automatically.
54+
:param port_file: File to write port that is used. ``None`` means
55+
file is not written.
56+
:param allow_stop: Allow/disallow stopping the server using
57+
``Stop Remote Server`` keyword.
58+
"""
4759
SimpleXMLRPCServer.__init__(self, (host, int(port)), logRequests=False)
4860
self._library = library
4961
self._allow_stop = allow_stop

0 commit comments

Comments
 (0)