[NUI][ACR-319][Add Position, Size two parameter constructor TCs] 69/237869/3
authorDongsug Song <dongsug.song@samsung.com>
Mon, 6 Jul 2020 08:05:44 +0000 (17:05 +0900)
committerDongsug Song <dongsug.song@samsung.com>
Thu, 9 Jul 2020 08:42:31 +0000 (17:42 +0900)
- This doesn't violate API break so it originally doesn't need ACR.
- However, API team requested ACR to maintain the history and manage API.
- Size and Position have already been public-released, so if exception is added the behavior will be changed also.
  This could make unexpected exception from VD application side and could make some user complain.
- I strongly recommand not to change the behavior for public-released API, so I don't want to change them.
  I politely request for you to consider current situation.

Change-Id: I9a8b156eb5109ff023456a7f30b67c27af8413f0

tct-suite-vs/Tizen.NUI.Tests/testcase/TSPosition.cs
tct-suite-vs/Tizen.NUI.Tests/testcase/TSSize.cs

index 6a710c3..2517361 100755 (executable)
@@ -54,6 +54,7 @@ namespace Tizen.NUI.Tests
         {
             /* TEST CODE */
             var position = new Position(0.5f, 0.5f, 0.5f);
+            Assert.IsNotNull(position, "The instance should be not null");
             Assert.IsInstanceOf<Position>(position, "Should return Position instance.");
             Assert.AreEqual(0.5f, position.X, "The X property of position is not correct here.");
             Assert.AreEqual(0.5f, position.Y, "The Y property of position is not correct here.");
@@ -810,5 +811,25 @@ namespace Tizen.NUI.Tests
             Assert.IsInstanceOf<Position>(position, "Should be an instance of Position type.");
             Assert.IsTrue(hash >= Int32.MinValue && hash <= Int32.MaxValue, "The value of hash is out of Integer range");
         }
+
+        [Test]
+        [Category("P1")]
+        [Description("Position constructor test, with two float values")]
+        [Property("SPEC", "Tizen.NUI.Position.Position C")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "CONSTR")]
+        [Property("COVPARAM", "Single, Single, Single")]
+        [Property("AUTHOR", "Feng Jin, feng16.jin@samsung.com")]
+        public void Position_INIT_WITH_FLOAT_FLOAT()
+        {
+            /* TEST CODE */
+            var position = new Position(0.5f, 0.5f);
+            Assert.IsNotNull(position, "The instance should be not null");
+            Assert.IsInstanceOf<Position>(position, "Should return Position instance.");
+            Assert.AreEqual(0.5f, position.X, "The X property of position is not correct here.");
+            Assert.AreEqual(0.5f, position.Y, "The Y property of position is not correct here.");
+            Assert.AreEqual(0.0f, position.Z, "The Z property of position is not correct here.");
+        }
+
     }
 }
index 164ea17..3264364 100755 (executable)
@@ -54,6 +54,7 @@ namespace Tizen.NUI.Tests
         {
             /* TEST CODE */
             var size = new Size(100.0f, 100.0f, 100.0f);
+            Assert.IsNotNull(size, "The instance should be not null");
             Assert.IsInstanceOf<Size>(size, "Should return Size instance.");
             Assert.AreEqual(100.0f, size.Width, "The Width property of position is not correct here.");
             Assert.AreEqual(100.0f, size.Height, "The Height property of position is not correct here.");
@@ -409,6 +410,27 @@ namespace Tizen.NUI.Tests
             Assert.IsInstanceOf<Size>(size, "Should be an instance of Size type.");
             Assert.IsTrue(hash >= Int32.MinValue && hash <= Int32.MaxValue, "The value of hash is out of Integer range");
         }
+
+
+        [Test]
+        [Category("P1")]
+        [Description("size constructor, with two float value parameters test")]
+        [Property("SPEC", "Tizen.NUI.Size.Size C")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "CONSTR")]
+        [Property("COVPARAM", "Single, Single, Single")]
+        [Property("AUTHOR", "Feng Jin, feng16.jin@samsung.com")]
+        public void Size_INIT_WITH_FLOAT_FLOAT()
+        {
+            /* TEST CODE */
+            var size = new Size(100.0f, 100.0f);
+            Assert.IsNotNull(size, "The instance should be not null");
+            Assert.IsInstanceOf<Size>(size, "Should return Size instance.");
+            Assert.AreEqual(100.0f, size.Width, "The Width property of position is not correct here.");
+            Assert.AreEqual(100.0f, size.Height, "The Height property of position is not correct here.");
+            Assert.AreEqual(0.0f, size.Depth, "The Depth property of position is not correct here.");
+        }
+
     }
 }