[Device][Non-ACR]Check whether profile is TV 93/286193/2
authorTaeminYeom <taemin.yeom@samsung.com>
Fri, 30 Dec 2022 03:33:18 +0000 (12:33 +0900)
committerTaemin Yeom <taemin.yeom@samsung.com>
Fri, 30 Dec 2022 06:59:25 +0000 (06:59 +0000)
display brightness is not supported on TV.
It should be disabled on TV profile.

Change-Id: I2ce07372afa26bac2060ef1b1229858253a1ca13
Signed-off-by: TaeminYeom <taemin.yeom@samsung.com>
tct-suite-vs/Tizen.Device.Tests/testcase/TSDisplay.cs

index 64e295e..bc94cf9 100755 (executable)
@@ -17,6 +17,7 @@ namespace Tizen.System.Tests
         {
             bool ret_value;
             bool value;
+            string str_value;
 
 
             ret_value = Tizen.System.Information.TryGetValue<bool>("tizen.org/feature/display", out value);
@@ -31,16 +32,22 @@ namespace Tizen.System.Tests
                 isDisplayStateSupport = 1;
             }
 
-            try
+            ret_value = Tizen.System.Information.TryGetValue<string>("tizen.org/feature/profile", out str_value);
+            if (ret_value && String.Compare(str_value, "tv", true) == 0)
             {
-                foreach (Display dis in Display.Displays)
+                isDisplayBrightnessSupport = 0;
+            } else {
+                try
                 {
-                    dis.Brightness = 30;
+                    foreach (Display dis in Display.Displays)
+                    {
+                        dis.Brightness = 30;
+                    }
+                }
+                catch (NotSupportedException e)
+                {
+                    isDisplayBrightnessSupport = 0;
                 }
-            }
-            catch (NotSupportedException e)
-            {
-                isDisplayBrightnessSupport = 0;
             }
         }