11TestLink API Python Client
22==========================
33
4- Copyright 2011-2012
5- James Stock, Olivier Renault, TestLink-API-Python-client developers
4+ Copyright 2011-2013
5+ James Stock, Olivier Renault, Luiko Czub, TestLink-API-Python-client developers
66
77License [ Apache License 2.0]
88
@@ -11,11 +11,19 @@ Introduction
1111
1212TestLink-API-Python-client is a Python XMLRPC client for the [ TestLink API] .
1313
14- It's a brick of Olivier Renault [ JinFeng] idea - an interaction of [ TestLink] ,
15- [ Robot Framework] and [ Jenkins] .
16-
17- Initially based on the James Stock testlink-api-python-client R7.
14+ Initially based on the James Stock testlink-api-python-client R7 and Olivier
15+ Renault [ JinFeng] idea - an interaction of [ TestLink] , [ Robot Framework] and [ Jenkins] .
1816
17+ TestLink-API-Python-client delivers two main classes
18+ * TestlinkAPIGeneric - Implements the Testlink API methods as generic PY
19+ methods with error handling.
20+ * Allows the configuration of arguments for these API method as positional
21+ or optional arguments.
22+
23+ * TestlinkAPIClient - Inherits Testlink API methods from the generic client
24+ TestlinkAPIGeneric and defines service methods like "countProjects".
25+ * Change the configuration for positional and optional arguments in a way,
26+ that often used arguments are positional (consistent with v0.4.0).
1927
2028Directory Layout
2129----------------
@@ -32,12 +40,19 @@ examples/
3240Installation
3341------------
3442
43+ ### TestLink configuration
44+ The testLink configuration (config.inc.php or custom_config.inc.php) must have enabled the api interface
45+ * $tlCfg->api->enabled = TRUE;
46+
47+ The user specific devKey are created inside TestLink, see
48+ * My Settings -> API interface - Personal API access key [ Generate a new key]
49+
3550### Install TestLinkAPI into a virtualenv environment
3651
3752```
3853[PYTHON27]\Scripts\virtualenv [PYENV]\testlink
3954[PYENV]\testlink\Scripts\activate
40- python setup.py install
55+ pip install TestLink-0.4.5-RC1.zip
4156```
4257
4358### Run example with command line arguments
@@ -48,6 +63,12 @@ python example\TestLinkExample.py
4863 --server_url http://[YOURSERVER]/testlink/lib/api/xmlrpc.php
4964 --devKey [Users devKey generated by TestLink]
5065```
66+ ```
67+ [PYENV]\testlink\Scripts\activate
68+ python example\TestLinkExampleGenericApi.py
69+ --server_url http://[YOURSERVER]/testlink/lib/api/xmlrpc.php
70+ --devKey [Users devKey generated by TestLink]
71+ ```
5172
5273### Run unittests with TestLink Server interaction
5374
@@ -75,13 +96,44 @@ Use http://[YOURSERVER]/testlink/lib/api/xmlrpc/v1/xmlrpc.php
7596Download
7697--------
7798
78- see [ downloads]
99+ see [ Releases]
100+ * please read [ v0.4.5 release notes] ( https://github.com/lczub/TestLink-API-Python-client/releases/tag/v0.4.5-RC1 )
101+ for changes between v0.4.0 and v0.4.5
102+
103+ Help
104+ ----
105+
106+ Questions, Enhancements, Issues are welcome under [ Issues]
79107
108+ For (nearly all) implemented API methods you find in
109+ [ example/TestLinkExample.py] ( example/TestLinkExample.py )
110+ an example, which although prints the reponse.
111+
112+ The Teslink API Client could be ask, what arguments a API method expects
113+
114+ ```
115+ import testlink
116+ tlh = testlink.TestLinkHelper()
117+ tls = tlh.connect(testlink.TestlinkAPIClient)
118+ print tls.whatArgs('createTestPlan')
119+ createTestPlan(<testplanname>, <testprojectname>, [note=<note>], [active=<active>], [public=<public>], [devKey=<devKey>])
120+ create a test plan
121+ ```
122+
123+ or a description of all implemented API method could be generated
124+
125+ ```
126+ import testlink
127+ tlh = testlink.TestLinkHelper()
128+ tls = tlh.connect(testlink.TestlinkAPIClient)
129+ for m in testlink.testlinkargs._apiMethodsArgs.keys():
130+ print tls.whatArgs(m), '\n'
131+ ```
80132
81133TestLink-API-Python-client developers
82134-------------------------------------
83135* [ James Stock] , [ Olivier Renault]
84- * [ g4l4drim] , [ pade] , [ lczub] , [ anton-matosov]
136+ * [ g4l4drim] , [ pade] , [ lczub] , [ anton-matosov] , [ citizen-stig ]
85137* anyone forgotten?
86138
87139
@@ -91,10 +143,12 @@ TestLink-API-Python-client developers
91143[ TestLink ] : http://www.teamst.org/
92144[ Robot Framework ] : http://code.google.com/p/robotframework
93145[ Jenkins ] : http://jenkins-ci.org/
94- [ downloads ] : https://github.com/lczub/TestLink-API-Python-client/downloads
146+ [ Releases ] : https://github.com/lczub/TestLink-API-Python-client/releases
147+ [ Issues ] : https://github.com/lczub/TestLink-API-Python-client/issues
95148[ Olivier Renault ] : https://github.com/orenault/TestLink-API-Python-client
96149[ pade ] : https://github.com/pade/TestLink-API-Python-client
97150[ g4l4drim ] : https://github.com/g4l4drim/TestLink-API-Python-client
98151[ James Stock ] : https://code.google.com/p/testlink-api-python-client/
99152[ lczub ] : https://github.com/lczub/TestLink-API-Python-client
100- [ anton-matosov ] : https://github.com/anton-matosov/TestLink-API-Python-client.git
153+ [ anton-matosov ] : https://github.com/anton-matosov/TestLink-API-Python-client
154+ [ citizen-stig ] : https://github.com/citizen-stig/TestLink-API-Python-client
0 commit comments