From 966c78d6906b7b412d125a57321c5080ead037b2 Mon Sep 17 00:00:00 2001 From: Petr Šplíchal Date: Mon, 13 Feb 2012 13:33:31 +0100 Subject: More optional values when creating a new test case --- source/api.py | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) (limited to 'source/api.py') diff --git a/source/api.py b/source/api.py index 3d22d96..f1cad00 100644 --- a/source/api.py +++ b/source/api.py @@ -2587,6 +2587,28 @@ class TestCase(Mutable): # Script hash["script"] = kwargs.get("script") + # Case Status + status = kwargs.get("status") + if status: + if isinstance(status, basestring): + status = CaseStatus(status) + hash["case_status"] = status.id + + # Automated + automated = kwargs.get("automated") + if automated is not None: + hash["is_automated"] = automated + + # Estimated time + time = kwargs.get("time") + if time is not None: + hash["estimated_time"] = time + + # Notes + notes = kwargs.get("notes") + if notes: + hash["notes"] = notes + # Submit log.info("Creating a new test case") log.debug(pretty(hash)) -- cgit