From: Kichan Kwon Date: Fri, 23 Mar 2018 08:36:42 +0000 (+0900) Subject: [Information][Auto][Non-ACR] Test battery TCs only if supported X-Git-Tag: public_m1_final~98^2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=3c3ef111a879774243fb315b40328802df76b51b;p=test%2Ftct%2Fcsharp%2Fapi.git [Information][Auto][Non-ACR] Test battery TCs only if supported Change-Id: I8a408c72200659e9647e7b0db11b020372cd5997 Signed-off-by: Kichan Kwon --- diff --git a/tct-suite-vs/Tizen.Information.Tests/testcase/TSInformation.cs b/tct-suite-vs/Tizen.Information.Tests/testcase/TSInformation.cs index 6d6b61a..8a373c0 100755 --- a/tct-suite-vs/Tizen.Information.Tests/testcase/TSInformation.cs +++ b/tct-suite-vs/Tizen.Information.Tests/testcase/TSInformation.cs @@ -75,15 +75,19 @@ namespace Tizen.System.Tests { isError = Information.TryGetValue("http://tizen.org/runtimefeature/audiojack.connected", out keyValueBool); Assert.IsTrue(isError, string.Format("TryGetValue return false for valid bool key: audiojack.connected")); - isError = Information.TryGetValue("http://tizen.org/runtimefeature/battery.charging", out keyValueBool); - Assert.IsTrue(isError, string.Format("TryGetValue return false for valid bool key: battery.charging")); + Information.TryGetValue("http://tizen.org/feature/battery", out supported); + if (supported) + { + isError = Information.TryGetValue("http://tizen.org/runtimefeature/battery.charging", out keyValueBool); + Assert.IsTrue(isError, string.Format("TryGetValue return false for valid bool key: battery.charging")); + + isError = Information.TryGetValue("http://tizen.org/runtimefeature/charger", out keyValueBool); + Assert.IsTrue(isError, string.Format("TryGetValue return false for valid bool key: charger")); + } isError = Information.TryGetValue("http://tizen.org/runtimefeature/tvout", out keyValueBool); Assert.IsTrue(isError, string.Format("TryGetValue return false for valid bool key: tvout")); - isError = Information.TryGetValue("http://tizen.org/runtimefeature/charger", out keyValueBool); - Assert.IsTrue(isError, string.Format("TryGetValue return false for valid bool key: charger")); - isError = Information.TryGetValue("http://tizen.org/runtimefeature/autorotation", out keyValueBool); Assert.IsTrue(isError, string.Format("TryGetValue return false for valid bool key: autorotation"));