From e93d70c0496ad8700143da87705abccdd884e4b4 Mon Sep 17 00:00:00 2001 From: Niranjan M.R Date: Jan 10 2019 03:44:44 +0000 Subject: [PATCH 1/2] Replace deprecated get_marker with get_closest_marker pytest==4.1 has deprecated get_marker and replaced with Node.get_closest_marker(name) Refer: https://github.com/pytest-dev/pytest/issues/4546 Signed-off-by: Niranjan M.R --- diff --git a/pytest_modifyjunit/plugin.py b/pytest_modifyjunit/plugin.py index d8c7c7f..934e453 100644 --- a/pytest_modifyjunit/plugin.py +++ b/pytest_modifyjunit/plugin.py @@ -49,7 +49,7 @@ class ModifyJunit(object): def _add_marks(self, item, report): """ add markers to the junit xml """ - mark_info = item.get_marker('xmlprop') + mark_info = item.get_closest_marker('xmlprop') if mark_info: if len(mark_info.args) % 2 != 0: raise ValueError('xmlprop marks must be set in name value pairs') From d8127dc43ad8fbdc55e1a507eca7c6ab6915a9e0 Mon Sep 17 00:00:00 2001 From: Niranjan M.R Date: Jan 10 2019 03:46:36 +0000 Subject: [PATCH 2/2] Update the version 1.5 Signed-off-by: Niranjan M.R --- diff --git a/setup.py b/setup.py index a368014..bb722dd 100644 --- a/setup.py +++ b/setup.py @@ -10,7 +10,7 @@ with io.open('README.rst', 'rt', encoding='utf-8') as f: setup_args = dict( name = "pytest-modifyjunit", - version = "1.4", + version = "1.5", description = "Utility for adding additional properties to junit xml for IDM QE", long_description = readme_contents, license = "GPL",