[NUI][TCSACR-403] Add FontSizeScale properties 72/253072/1
authorYoungbok Shin <youngb.shin@samsung.com>
Thu, 4 Feb 2021 07:23:03 +0000 (16:23 +0900)
committerYoungbok Shin <youngb.shin@samsung.com>
Thu, 4 Feb 2021 07:25:05 +0000 (16:25 +0900)
Change-Id: I839360225b5043ea0eeb8fc11bb9118bc941ad5a

tct-suite-vs/Tizen.NUI.Tests/testcase/TSTextEditor.cs
tct-suite-vs/Tizen.NUI.Tests/testcase/TSTextField.cs
tct-suite-vs/Tizen.NUI.Tests/testcase/TSTextLabel.cs

index ed7daf9..c3c22f6 100755 (executable)
@@ -1186,5 +1186,21 @@ namespace Tizen.NUI.Tests
             Assert.AreEqual(true, ret, "should be same");
         }
 
+        [Test]
+        [Category("P1")]
+        [Description("Test FontSizeScale. Check the default FontSizeScale and whether FontSizeScale is readable and writable.")]
+        [Property("SPEC", "Tizen.NUI.BaseComponents.TextEditor.FontSizeScale A")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "PRW")]
+        [Property("AUTHOR", "Youngbok Shin, youngb.shin@samsung.com")]
+        public void FontSizeScale_SET_GET_VALUE()
+        {
+            /* TEST CODE */
+            TextEditor textEditor = new TextEditor();
+            Assert.AreEqual(1.0, textEditor.FontSizeScale, "Retrieved the default FontSizeScale should be equal to 1.0");
+            float scale = 0.5f;
+            textEditor.FontSizeScale = scale;
+            Assert.AreEqual(scale, textEditor.FontSizeScale, "Retrieved FontSizeScale should be equal to set value");
+        }
     }
 }
index ee43b19..888d66c 100755 (executable)
@@ -1226,5 +1226,22 @@ namespace Tizen.NUI.Tests
             ret = textField.MatchSystemLanguageDirection;
             Assert.AreEqual(true, ret, "should be same");
         }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test FontSizeScale. Check the default FontSizeScale whether FontSizeScale is readable and writable.")]
+        [Property("SPEC", "Tizen.NUI.BaseComponents.TextField.FontSizeScale A")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "PRW")]
+        [Property("AUTHOR", "Youngbok Shin, youngb.shin@samsung.com")]
+        public void FontSizeScale_SET_GET_VALUE()
+        {
+            /* TEST CODE */
+            TextField textField = new TextField();
+            Assert.AreEqual(1.0, textField.FontSizeScale, "Retrieved the default FontSizeScale should be equal to 1.0");
+            float scale = 0.5f;
+            textField.FontSizeScale = scale;
+            Assert.AreEqual(scale, textField.FontSizeScale, "Retrieved FontSizeScale should be equal to set value");
+        }
     }
 }
index 61296f0..50b5039 100755 (executable)
@@ -745,6 +745,22 @@ namespace Tizen.NUI.Tests
             Assert.AreEqual(true, ret, "should be same");
         }
 
+        [Test]
+        [Category("P1")]
+        [Description("Test FontSizeScale. Check the default FontSizeScale and whether FontSizeScale is readable and writable.")]
+        [Property("SPEC", "Tizen.NUI.BaseComponents.TextLabel.FontSizeScale A")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "PRW")]
+        [Property("AUTHOR", "Youngbok Shin, youngb.shin@samsung.com")]
+        public void FontSizeScale_SET_GET_VALUE()
+        {
+            /* TEST CODE */
+            TextLabel textLabel = new TextLabel();
+            Assert.AreEqual(1.0, textLabel.FontSizeScale, "Retrieved the default FontSizeScale should be equal to 1.0");
+            float scale = 0.5f;
+            textLabel.FontSizeScale = scale;
+            Assert.AreEqual(scale, textLabel.FontSizeScale, "Retrieved FontSizeScale should be equal to set value");
+        }
     }
 
     public class MyTexLabel : TextLabel