From 2e551c32b6fd42352c2ef20d324b7a91955c9af6 Mon Sep 17 00:00:00 2001 From: Joseph Hunkeler Date: Mon, 3 Dec 2018 09:56:21 -0500 Subject: [PATCH] Add junit_family config option --- src/_pytest/junitxml.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/_pytest/junitxml.py b/src/_pytest/junitxml.py index 6286e442a..80ca92471 100644 --- a/src/_pytest/junitxml.py +++ b/src/_pytest/junitxml.py @@ -309,6 +309,9 @@ def pytest_addoption(parser): "Duration time to report: one of total|call", default="total", ) # choices=['total', 'call']) + parser.addini( + "junit_family", "Emit XML for schema: one of old|xunit1|xunit2", default="old" + ) def pytest_configure(config): @@ -321,6 +324,7 @@ def pytest_configure(config): config.getini("junit_suite_name"), config.getini("junit_logging"), config.getini("junit_duration_report"), + config.getini("junit_family"), ) config.pluginmanager.register(config._xml)