testit-adapter-pytest 3.5.5.post530__tar.gz → 3.6.0.post530__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (18) hide show
  1. {testit_adapter_pytest-3.5.5.post530 → testit_adapter_pytest-3.6.0.post530}/PKG-INFO +11 -2
  2. {testit_adapter_pytest-3.5.5.post530 → testit_adapter_pytest-3.6.0.post530}/README.md +9 -0
  3. {testit_adapter_pytest-3.5.5.post530 → testit_adapter_pytest-3.6.0.post530}/setup.py +1 -1
  4. {testit_adapter_pytest-3.5.5.post530 → testit_adapter_pytest-3.6.0.post530}/src/testit_adapter_pytest/listener.py +46 -1
  5. {testit_adapter_pytest-3.5.5.post530 → testit_adapter_pytest-3.6.0.post530}/src/testit_adapter_pytest/utils.py +4 -3
  6. {testit_adapter_pytest-3.5.5.post530 → testit_adapter_pytest-3.6.0.post530}/src/testit_adapter_pytest.egg-info/PKG-INFO +11 -2
  7. testit_adapter_pytest-3.6.0.post530/src/testit_adapter_pytest.egg-info/requires.txt +4 -0
  8. testit_adapter_pytest-3.5.5.post530/src/testit_adapter_pytest.egg-info/requires.txt +0 -4
  9. {testit_adapter_pytest-3.5.5.post530 → testit_adapter_pytest-3.6.0.post530}/setup.cfg +0 -0
  10. {testit_adapter_pytest-3.5.5.post530 → testit_adapter_pytest-3.6.0.post530}/src/testit_adapter_pytest/__init__.py +0 -0
  11. {testit_adapter_pytest-3.5.5.post530 → testit_adapter_pytest-3.6.0.post530}/src/testit_adapter_pytest/fixture_context.py +0 -0
  12. {testit_adapter_pytest-3.5.5.post530 → testit_adapter_pytest-3.6.0.post530}/src/testit_adapter_pytest/models/__init__.py +0 -0
  13. {testit_adapter_pytest-3.5.5.post530 → testit_adapter_pytest-3.6.0.post530}/src/testit_adapter_pytest/models/executable_test.py +0 -0
  14. {testit_adapter_pytest-3.5.5.post530 → testit_adapter_pytest-3.6.0.post530}/src/testit_adapter_pytest/plugin.py +0 -0
  15. {testit_adapter_pytest-3.5.5.post530 → testit_adapter_pytest-3.6.0.post530}/src/testit_adapter_pytest.egg-info/SOURCES.txt +0 -0
  16. {testit_adapter_pytest-3.5.5.post530 → testit_adapter_pytest-3.6.0.post530}/src/testit_adapter_pytest.egg-info/dependency_links.txt +0 -0
  17. {testit_adapter_pytest-3.5.5.post530 → testit_adapter_pytest-3.6.0.post530}/src/testit_adapter_pytest.egg-info/entry_points.txt +0 -0
  18. {testit_adapter_pytest-3.5.5.post530 → testit_adapter_pytest-3.6.0.post530}/src/testit_adapter_pytest.egg-info/top_level.txt +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: testit-adapter-pytest
3
- Version: 3.5.5.post530
3
+ Version: 3.6.0.post530
4
4
  Summary: Pytest adapter for Test IT
5
5
  Home-page: https://github.com/testit-tms/adapters-python/
6
6
  Author: Integration team
@@ -16,7 +16,7 @@ Description-Content-Type: text/markdown
16
16
  Requires-Dist: pytest
17
17
  Requires-Dist: pytest-xdist
18
18
  Requires-Dist: attrs
19
- Requires-Dist: testit-python-commons==3.5.5.post530
19
+ Requires-Dist: testit-python-commons==3.6.0.post530
20
20
  Dynamic: author
21
21
  Dynamic: author-email
22
22
  Dynamic: classifier
@@ -139,9 +139,18 @@ All decorators support the use of parameterization attributes
139
139
 
140
140
  Description of methods:
141
141
 
142
+ - `testit.addWorkItemIds` - a dynamic method that links autotests with manual tests. Receives the array of manual tests' IDs
143
+ - `testit.addDisplayName` - a dynamic method for adding internal autotest name (used in Test IT)
144
+ - `testit.addExternalId` - a dynamic method for adding unique internal autotest ID (used in Test IT)
145
+ - `testit.addTitle` - a dynamic method for adding autotest name specified in the autotest card. If not specified, the name from the displayName method is used
146
+ - `testit.addDescription` - a dynamic method for adding autotest description specified in the autotest card
147
+ - `testit.addLabels` - a dynamic method for adding tags listed in the autotest card
142
148
  - `testit.addLinks` - links in the autotest result
143
149
  - `testit.addAttachments` - uploading files in the autotest result
144
150
  - `testit.addMessage` - information about autotest in the autotest result
151
+ - `testit.addNameSpace` - a dynamic method for adding directory in the TMS system (default - file's name of test)
152
+ - `testit.addClassName` - a dynamic method for adding subdirectory in the TMS system (default - class's name of test)
153
+ - `testit.addParameter` - a dynamic method for adding parameter in the autotest result
145
154
  - `testit.step` - usage in the "with" construct to designation a step in the body of the test
146
155
 
147
156
  ### Examples
@@ -110,9 +110,18 @@ All decorators support the use of parameterization attributes
110
110
 
111
111
  Description of methods:
112
112
 
113
+ - `testit.addWorkItemIds` - a dynamic method that links autotests with manual tests. Receives the array of manual tests' IDs
114
+ - `testit.addDisplayName` - a dynamic method for adding internal autotest name (used in Test IT)
115
+ - `testit.addExternalId` - a dynamic method for adding unique internal autotest ID (used in Test IT)
116
+ - `testit.addTitle` - a dynamic method for adding autotest name specified in the autotest card. If not specified, the name from the displayName method is used
117
+ - `testit.addDescription` - a dynamic method for adding autotest description specified in the autotest card
118
+ - `testit.addLabels` - a dynamic method for adding tags listed in the autotest card
113
119
  - `testit.addLinks` - links in the autotest result
114
120
  - `testit.addAttachments` - uploading files in the autotest result
115
121
  - `testit.addMessage` - information about autotest in the autotest result
122
+ - `testit.addNameSpace` - a dynamic method for adding directory in the TMS system (default - file's name of test)
123
+ - `testit.addClassName` - a dynamic method for adding subdirectory in the TMS system (default - class's name of test)
124
+ - `testit.addParameter` - a dynamic method for adding parameter in the autotest result
116
125
  - `testit.step` - usage in the "with" construct to designation a step in the body of the test
117
126
 
118
127
  ### Examples
@@ -1,6 +1,6 @@
1
1
  from setuptools import find_packages, setup
2
2
 
3
- VERSION = "3.5.5.post530"
3
+ VERSION = "3.6.0.post530"
4
4
 
5
5
  setup(
6
6
  name='testit-adapter-pytest',
@@ -267,7 +267,7 @@ class TmsListener(object):
267
267
  self.__executable_test.result_links.append(link)
268
268
 
269
269
  @adapter.hookimpl
270
- def add_message(self, test_message):
270
+ def add_message(self, test_message: str):
271
271
  if self.__executable_test:
272
272
  self.__executable_test.message = str(test_message)
273
273
 
@@ -281,6 +281,51 @@ class TmsListener(object):
281
281
  if self.__executable_test:
282
282
  self.__executable_test.attachments += self.__adapter_manager.create_attachment(body, name)
283
283
 
284
+ @adapter.hookimpl
285
+ def add_work_item_id(self, test_work_item_id: str):
286
+ if not self.__executable_test:
287
+ self.__executable_test.work_item_ids.append(test_work_item_id)
288
+
289
+ @adapter.hookimpl
290
+ def add_display_name(self, test_display_name: str):
291
+ if self.__executable_test:
292
+ self.__executable_test.name = test_display_name
293
+
294
+ @adapter.hookimpl
295
+ def add_namespace(self, test_namespace: str):
296
+ if self.__executable_test:
297
+ self.__executable_test.namespace = test_namespace
298
+
299
+ @adapter.hookimpl
300
+ def add_classname(self, test_classname: str):
301
+ if self.__executable_test:
302
+ self.__executable_test.classname = test_classname
303
+
304
+ @adapter.hookimpl
305
+ def add_external_id(self, test_external_id: str):
306
+ if self.__executable_test:
307
+ self.__executable_test.external_id = test_external_id
308
+
309
+ @adapter.hookimpl
310
+ def add_title(self, test_title: str):
311
+ if self.__executable_test:
312
+ self.__executable_test.title = str(test_title)
313
+
314
+ @adapter.hookimpl
315
+ def add_description(self, test_description: str):
316
+ if self.__executable_test:
317
+ self.__executable_test.description = test_description
318
+
319
+ @adapter.hookimpl
320
+ def add_label(self, test_label: str):
321
+ if self.__executable_test:
322
+ self.__executable_test.labels.append({'name': test_label})
323
+
324
+ @adapter.hookimpl
325
+ def add_parameter(self, name: str, value: str):
326
+ if self.__executable_test:
327
+ self.__executable_test.parameters[name] = value
328
+
284
329
  @adapter.hookimpl
285
330
  def start_fixture(self, parent_uuid, uuid, title):
286
331
  after_fixture = FixtureResult(title=title)
@@ -121,12 +121,13 @@ def __get_links_from(item):
121
121
 
122
122
 
123
123
  def __get_parameters_from(item):
124
+ test_parameters = {}
125
+
124
126
  if hasattr(item, 'callspec'):
125
- test_parameters = {}
126
127
  for key, parameter in item.callspec.params.items():
127
128
  test_parameters[key] = str(parameter)
128
- return test_parameters
129
- return None
129
+
130
+ return test_parameters
130
131
 
131
132
 
132
133
  def __get_properties_from(item):
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: testit-adapter-pytest
3
- Version: 3.5.5.post530
3
+ Version: 3.6.0.post530
4
4
  Summary: Pytest adapter for Test IT
5
5
  Home-page: https://github.com/testit-tms/adapters-python/
6
6
  Author: Integration team
@@ -16,7 +16,7 @@ Description-Content-Type: text/markdown
16
16
  Requires-Dist: pytest
17
17
  Requires-Dist: pytest-xdist
18
18
  Requires-Dist: attrs
19
- Requires-Dist: testit-python-commons==3.5.5.post530
19
+ Requires-Dist: testit-python-commons==3.6.0.post530
20
20
  Dynamic: author
21
21
  Dynamic: author-email
22
22
  Dynamic: classifier
@@ -139,9 +139,18 @@ All decorators support the use of parameterization attributes
139
139
 
140
140
  Description of methods:
141
141
 
142
+ - `testit.addWorkItemIds` - a dynamic method that links autotests with manual tests. Receives the array of manual tests' IDs
143
+ - `testit.addDisplayName` - a dynamic method for adding internal autotest name (used in Test IT)
144
+ - `testit.addExternalId` - a dynamic method for adding unique internal autotest ID (used in Test IT)
145
+ - `testit.addTitle` - a dynamic method for adding autotest name specified in the autotest card. If not specified, the name from the displayName method is used
146
+ - `testit.addDescription` - a dynamic method for adding autotest description specified in the autotest card
147
+ - `testit.addLabels` - a dynamic method for adding tags listed in the autotest card
142
148
  - `testit.addLinks` - links in the autotest result
143
149
  - `testit.addAttachments` - uploading files in the autotest result
144
150
  - `testit.addMessage` - information about autotest in the autotest result
151
+ - `testit.addNameSpace` - a dynamic method for adding directory in the TMS system (default - file's name of test)
152
+ - `testit.addClassName` - a dynamic method for adding subdirectory in the TMS system (default - class's name of test)
153
+ - `testit.addParameter` - a dynamic method for adding parameter in the autotest result
145
154
  - `testit.step` - usage in the "with" construct to designation a step in the body of the test
146
155
 
147
156
  ### Examples
@@ -0,0 +1,4 @@
1
+ pytest
2
+ pytest-xdist
3
+ attrs
4
+ testit-python-commons==3.6.0.post530
@@ -1,4 +0,0 @@
1
- pytest
2
- pytest-xdist
3
- attrs
4
- testit-python-commons==3.5.5.post530