[NUI.Components][ACR-329]Fix failed tcs using subclass 21/236021/22
authorzg2nets <zg84.zhang@samsung.com>
Fri, 12 Jun 2020 04:43:10 +0000 (13:43 +0900)
committerzhang zhigang <zg84.zhang@samsung.com>
Mon, 6 Jul 2020 08:56:04 +0000 (08:56 +0000)
 - http://10.113.10.143:8080/job/TV-RPI4-CSHARP-TCT-60/106/artifact/result/TCT_CSHARP/Tizen.NUI.Components.Tests.xml

Change-Id: If71d0b2f432fb3ac59b1bc5b2948ce542664b785

tct-suite-vs/Tizen.NUI.Components.Tests/Tizen.NUI.Components.Tests.csproj [changed mode: 0755->0644]
tct-suite-vs/Tizen.NUI.Components.Tests/testcase/TSButton.cs [changed mode: 0755->0644]
tct-suite-vs/Tizen.NUI.Components.Tests/testcase/TSLoading.cs [changed mode: 0755->0644]
tct-suite-vs/Tizen.NUI.Components.Tests/testcase/TSPopup.cs [changed mode: 0755->0644]
tct-suite-vs/Tizen.NUI.Components.Tests/testcase/TSProgress.cs [changed mode: 0755->0644]
tct-suite-vs/Tizen.NUI.Components.Tests/testcase/TSScrollBar.cs [changed mode: 0755->0644]
tct-suite-vs/Tizen.NUI.Components.Tests/testcase/TSSlider.cs [changed mode: 0755->0644]
tct-suite-vs/Tizen.NUI.Components.Tests/testcase/TSSwitch.cs [changed mode: 0755->0644]
tct-suite-vs/Tizen.NUI.Components.Tests/testcase/TSTab.cs [changed mode: 0755->0644]
tct-suite-vs/Tizen.NUI.Components.Tests/testcase/TSToast.cs [changed mode: 0755->0644]

old mode 100755 (executable)
new mode 100644 (file)
index de794b8..6ebe926
@@ -17,7 +17,6 @@ namespace Tizen.NUI.Components.Tests
         private const string TAG = "Components";
         private bool _stateChangedEvent = false;
         private string _image_path = Tizen.Applications.Application.Current.DirectoryInfo.Resource + "picture.png";
-        private static bool _flagGetViewStyle = false;
         private static bool _flagOnThemeChangedEvent = false;
 
         [SetUp]
@@ -84,11 +83,8 @@ namespace Tizen.NUI.Components.Tests
                 Assert.Fail("Should throw the Exception: There is no style of defaultButtonX !");
             }
             catch(InvalidOperationException e)
-            {\r
-                if (e != null)
-                {
-                    Assert.Pass("InvalidOperationException: passed!");
-                }\r
+            {
+                Assert.Pass("InvalidOperationException: passed!");
             }
         }
 
@@ -331,10 +327,7 @@ namespace Tizen.NUI.Components.Tests
             }
             catch(NullReferenceException e)
             {
-                if (e != null)\r
-                {
-                    Assert.Pass("NullReferenceException: passed!");
-                }
+                Assert.Pass("NullReferenceException: passed!");
             }
         }
 
@@ -384,11 +377,8 @@ namespace Tizen.NUI.Components.Tests
                 Assert.Fail("Should throw the NullReferenceException!");
             }
             catch (NullReferenceException e)
-            {\r
-                if (e != null)\r
-                {
-                    Assert.Pass("NullReferenceException: passed!");
-                }\r
+            {
+                Assert.Pass("NullReferenceException: passed!");
             }
         }
 
@@ -445,11 +435,8 @@ namespace Tizen.NUI.Components.Tests
                 Assert.Fail("Should throw the NullReferenceException!");
             }
             catch(NullReferenceException e)
-            {\r
-                if (e != null)\r
-                {
-                    Assert.Pass("NullReferenceException: passed!");
-                }\r
+            {
+                Assert.Pass("NullReferenceException: passed!");
             }
         }
 
@@ -499,11 +486,8 @@ namespace Tizen.NUI.Components.Tests
                 Assert.Fail("Should throw the NullReferenceException!");
             }
             catch(NullReferenceException e)
-            {\r
-                if (e != null)\r
-                {
-                    Assert.Pass("NullReferenceException: passed!");
-                }\r
+            {
+                Assert.Pass("NullReferenceException: passed!");
             }
         }
 
@@ -552,11 +536,8 @@ namespace Tizen.NUI.Components.Tests
                 Assert.Fail("Should throw the NullReferenceException!");
             }
             catch(NullReferenceException e)
-            {\r
-                if (e != null)\r
-                {
-                    Assert.Pass("NullReferenceException: passed!");
-                }\r
+            {
+                Assert.Pass("NullReferenceException: passed!");
             }
         }
 
@@ -738,20 +719,18 @@ namespace Tizen.NUI.Components.Tests
 
         [Test]
         [Category("P1")]
-        [Description("Test GetViewStyle. Check whether GetViewStyle works or not.")]
-        [Property("SPEC", "Tizen.NUI.Components.Button.GetViewStyle M")]
+        [Description("Test CreateViewStyle. Check whether CreateViewStyle works or not.")]
+        [Property("SPEC", "Tizen.NUI.Components.Button.CreateViewStyle M")]
         [Property("SPEC_URL", " - ")]
         [Property("CRITERIA", "MR")]
         [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]
-        public void GetViewStyle_CHECK_RETURN_VALUE()
+        public void CreateViewStyle_CHECK_RETURN_VALUE()
         {
             try
             {
-                _flagGetViewStyle = false;
                 var button = new MyButton();
-                var style = button.Style;
+                ViewStyle style = button.CreateMyViewStyle();
                 Assert.IsNotNull(style, "Should be not null");
-                Assert.IsTrue(_flagGetViewStyle, "Should be true!");
             }
             catch (Exception e)
             {
@@ -790,12 +769,11 @@ namespace Tizen.NUI.Components.Tests
 
         public class MyButton : Button
         {
-            public MyButton () : base() {}
+            public MyButton() : base() {}\r
 
-            protected override ViewStyle GetViewStyle()
+            public ViewStyle CreateMyViewStyle()
             {
-                _flagGetViewStyle = true;
-                return base.GetViewStyle();
+                return base.CreateViewStyle();
             }
 
             protected override void OnThemeChangedEvent(object sender, StyleManager.ThemeChangeEventArgs e)
old mode 100755 (executable)
new mode 100644 (file)
index 64663d4..450041d
@@ -13,7 +13,6 @@ namespace Tizen.NUI.Components.Tests
     public class LoadingTests
     {
         private const string TAG = "Components";
-        private static bool _flagGetViewStyle = false;
 
         [SetUp]
         public void Init()
@@ -212,24 +211,22 @@ namespace Tizen.NUI.Components.Tests
                 LogUtils.Write(LogUtils.DEBUG, LogUtils.TAG, "Caught Exception" + e.ToString());
                 Assert.Fail("Caught Exception" + e.ToString());
             }
-        }
-
+        }\r
+\r
         [Test]
         [Category("P1")]
-        [Description("Test GetViewStyle. Check whether GetViewStyle works or not.")]
-        [Property("SPEC", "Tizen.NUI.Components.Loading.GetViewStyle M")]
+        [Description("Test CreateViewStyle. Check whether CreateViewStyle works or not.")]
+        [Property("SPEC", "Tizen.NUI.Components.Loading.CreateViewStyle M")]
         [Property("SPEC_URL", " - ")]
         [Property("CRITERIA", "MR")]
         [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]
-        public void GetViewStyle_CHECK_RETURN_VALUE()
+        public void CreateViewStyle_CHECK_RETURN_VALUE()
         {
             try
             {
-                _flagGetViewStyle = false;
                 var loading = new MyLoading();
-                var style = loading.Style;
+                ViewStyle style = loading.CreateMyViewStyle();
                 Assert.IsNotNull(style, "Should be not null");
-                Assert.IsTrue(_flagGetViewStyle, "Should be true!");
             }
             catch (Exception e)
             {
@@ -239,15 +236,13 @@ namespace Tizen.NUI.Components.Tests
 
         public class MyLoading : Loading
         {
-            public MyLoading() : base() {}
+            public MyLoading() : base() { }
 
-            protected override ViewStyle GetViewStyle()
+            public ViewStyle CreateMyViewStyle()
             {
-                _flagGetViewStyle = true;
-                return base.GetViewStyle();
+                return base.CreateViewStyle();
             }
         }
-
         public class DefaultLoadingStyle : StyleBase
         {
             protected override ViewStyle GetViewStyle()
old mode 100755 (executable)
new mode 100644 (file)
index 3af1953..8475d73
-using NUnit.Framework;\r
-using NUnit.Framework.TUnit;\r
-using System;\r
-using Tizen.NUI;\r
-using Tizen.NUI.Components;\r
-using Tizen.NUI.BaseComponents;\r
-using System.Runtime.InteropServices;\r
-using System.Threading.Tasks;\r
-using Tizen.NUI.Components.Test;\r
-\r
-namespace Tizen.NUI.Components.Tests\r
-{\r
-    [TestFixture]\r
-    [Description("Tizen.NUI.Components.Popup Tests")]\r
-    public class PopupTests\r
-    {\r
-        private const string TAG = "Components";\r
-        private string _image_path = Tizen.Applications.Application.Current.DirectoryInfo.Resource + "picture.png";\r
-        private string _path = Tizen.Applications.Application.Current.DirectoryInfo.Resource;\r
-        private static bool _flagGetViewStyle = false;\r
-        private static bool _flagOnThemeChangedEvent = false;\r
-\r
-        [SetUp]\r
-        public void Init()\r
-        {\r
-            Tizen.Log.Info(TAG, "Init() is called!");\r
-        }\r
-\r
-        [TearDown]\r
-        public void Destroy()\r
-        {\r
-            Tizen.Log.Info(TAG, "Destroy() is called!");\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test Popup empty constructor. Check it has been triggered")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Popup.Popup C")]\r
-        [Property("SPEC_URL", "-")]\r
-        [Property("CRITERIA", "CONSTR")]\r
-        [Property("COVPARAM", "")]\r
-        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]\r
-        public void Popup_CHECK_VALUE()\r
-        {\r
-            /* TEST CODE */\r
-            var popup = new Components.Popup();\r
-            Assert.IsNotNull(popup, "Should be not Null!");\r
-            Assert.IsInstanceOf<Components.Popup>(popup, "Should be equal!");\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test Popup constructor using string. Check whether Popup is successfully created or not.")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Popup.Popup C")]\r
-        [Property("SPEC_URL", "-")]\r
-        [Property("CRITERIA", "CONSTR")]\r
-        [Property("COVPARAM", "string")]\r
-        [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]\r
-        public void Popup_INIT_WITH_STRING()\r
-        {\r
-            /* TEST CODE */\r
-            StyleManager.Instance.Theme = "default";\r
-            StyleManager.Instance.RegisterStyle("defaultPopup", "default", typeof(DefaultPopupStyle));\r
-            var popup = new Popup("defaultPopup");\r
-            Assert.IsNotNull(popup, "Should be not null!");\r
-            Assert.IsInstanceOf<Popup>(popup, "Should be an instance of Popup!");\r
-        }\r
-\r
-        [Test]\r
-        [Category("P2")]\r
-        [Description("Check exception when constructing a Popup with nonexistent style")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Popup.Popup C")]\r
-        [Property("SPEC_URL", "-")]\r
-        [Property("CRITERIA", "CONSTX")]\r
-        [Property("COVPARAM", "string")]\r
-        [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]\r
-        public void Popup_INIT_WITH_STRING_Exception()\r
-        {\r
-            /* TEST CODE */\r
-            try\r
-            {\r
-                var popup = new Popup("defaultPopupX");\r
-                Assert.Fail("Should throw the Exception: There is no style of defaultPopupX !");\r
-            }\r
-            catch(InvalidOperationException e)\r
-            {\r
-                if (e != null)\r
-                {\r
-                    Assert.Pass("InvalidOperationException: passed!");\r
-                }\r
-            }\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test Popup constructor using style. Check whether Popup is successfully created or not.")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Popup.Popup C")]\r
-        [Property("SPEC_URL", "-")]\r
-        [Property("CRITERIA", "CONSTR")]\r
-        [Property("COVPARAM", "PopupStyle")]\r
-        [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]\r
-        public void Popup_INIT_WITH_STYLE()\r
-        {\r
-            /* TEST CODE */\r
-            var style = new PopupStyle();\r
-            Assert.IsNotNull(style, "Should be not null!");\r
-            Assert.IsInstanceOf<PopupStyle>(style, "Should be an instance of PopupStyle!");\r
-\r
-            var popup = new Popup(style);\r
-            Assert.IsNotNull(popup, "Should be not null!");\r
-            Assert.IsInstanceOf<Popup>(popup, "Should be an instance of Popup!");\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test Style. Check whether Style is readable.")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Popup.Style A")]\r
-        [Property("SPEC_URL", "-")]\r
-        [Property("CRITERIA", "PRO")]\r
-        [Property("AUTHOR", "Xianbing teng, xb.teng@samsung.com")]\r
-        public void Style_CHECK_GET_VALUE()\r
-        {\r
-            /* TEST CODE */\r
-            var popup = new Popup();\r
-            Assert.IsNotNull(popup, "Should be not null");\r
-            Assert.IsInstanceOf<Popup>(popup, "Should be an instance of Popup!");\r
-\r
-            var style = popup.Style;\r
-            Assert.IsNotNull(style, "Should be not null");\r
-            Assert.IsInstanceOf<PopupStyle>(style, "Should be an instance of PopupStyle!");\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test TitleText. Check whether TitleText is readable and writable.")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Popup.TitleText A")]\r
-        [Property("SPEC_URL", "-")]\r
-        [Property("CRITERIA", "PRW")]\r
-        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]\r
-        public void TitleText_SET_GET_VALUE()\r
-        {\r
-            /* TEST CODE */\r
-            var popup = new Components.Popup();\r
-            Assert.IsNotNull(popup, "Should be not Null!");\r
-            Assert.IsInstanceOf<Components.Popup>(popup, "Should be equal!");\r
-\r
-            popup.TitleText = "Test TitleText";\r
-            Assert.AreEqual("Test TitleText", popup.TitleText, "Should be equals to the set value of TitleText");\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test ButtonCount. Check whether ButtonCount is readable and writable.")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Popup.ButtonCount A")]\r
-        [Property("SPEC_URL", "-")]\r
-        [Property("CRITERIA", "PRW")]\r
-        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]\r
-        public void ButtonCount_SET_GET_VALUE()\r
-        {\r
-            /* TEST CODE */\r
-            var popup = new Components.Popup();\r
-            Assert.IsNotNull(popup, "Should be not Null!");\r
-            Assert.IsInstanceOf<Components.Popup>(popup, "Should be equal!");\r
-\r
-            popup.ButtonCount = 2;\r
-            Assert.AreEqual(2, popup.ButtonCount, "Should be equals to the set value of ButtonCount");\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test ContentView. Check whether ContentView is readable.")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Popup.ContentView A")]\r
-        [Property("SPEC_URL", "-")]\r
-        [Property("CRITERIA", "PRO")]\r
-        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]\r
-        public void ContentView_GET_VALUE()\r
-        {\r
-            /* TEST CODE */\r
-            var popup = new Components.Popup();\r
-            Assert.IsNotNull(popup.ContentView, "Should be equals!");\r
-            Assert.IsInstanceOf<BaseComponents.View>(popup.ContentView, "Should be an instance of view!");\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test TitlePointSize. Check whether TitlePointSize is readable and writable.")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Popup.TitlePointSize A")]\r
-        [Property("SPEC_URL", "-")]\r
-        [Property("CRITERIA", "PRW")]\r
-        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]\r
-        public void TitlePointSize_SET_GET_VALUE()\r
-        {\r
-            /* TEST CODE */\r
-            var popup = new Components.Popup();\r
-            Assert.IsNotNull(popup, "Should be not Null!");\r
-            Assert.IsInstanceOf<Components.Popup>(popup, "Should be equal!");\r
-\r
-            popup.TitlePointSize = 10.0f;\r
-            Assert.AreEqual(10.0f, popup.TitlePointSize, "Should be equals to the set value of TitlePointSize");\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test TitleTextColor. Check whether TitleTextColor is readable and writable.")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Popup.TitleTextColor A")]\r
-        [Property("SPEC_URL", "-")]\r
-        [Property("CRITERIA", "PRW")]\r
-        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]\r
-        public void TitleTextColor_SET_GET_VALUE()\r
-        {\r
-            /* TEST CODE */\r
-            var popup = new Components.Popup();\r
-            Assert.IsNotNull(popup, "Should be not Null!");\r
-            Assert.IsInstanceOf<Components.Popup>(popup, "Should be equal!");\r
-\r
-            var color = new Color(1.0f, 0.0f, 0.0f, 1.0f);\r
-            Assert.IsNotNull(color, "Should be not Null!");\r
-            Assert.IsInstanceOf<Color>(color, "Should be equal!");\r
-            popup.TitleTextColor = color;\r
-\r
-            Assert.AreEqual(color.R, popup.TitleTextColor.R, "Should be equals to the color.R set");\r
-            Assert.AreEqual(color.G, popup.TitleTextColor.G, "Should be equals to the color.G set");\r
-            Assert.AreEqual(color.B, popup.TitleTextColor.B, "Should be equals to the color.B set");\r
-            Assert.AreEqual(color.A, popup.TitleTextColor.A, "Should be equals to the color.A set");\r
-\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test TitleTextHorizontalAlignment. Check whether TitleTextHorizontalAlignment is readable and writable.")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Popup.TitleTextHorizontalAlignment A")]\r
-        [Property("SPEC_URL", "-")]\r
-        [Property("CRITERIA", "PRW")]\r
-        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]\r
-        public void TitleTextHorizontalAlignment_SET_GET_VALUE()\r
-        {\r
-            /* TEST CODE */\r
-            var popup = new Components.Popup();\r
-            Assert.IsNotNull(popup, "Should be not Null!");\r
-            Assert.IsInstanceOf<Components.Popup>(popup, "Should be equal!");\r
-\r
-            popup.TitleTextHorizontalAlignment = HorizontalAlignment.Begin;\r
-            Assert.AreEqual(HorizontalAlignment.Begin, popup.TitleTextHorizontalAlignment, "Should be equals to the set value of TitleTextHorizontalAlignment");\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test TitleTextPosition. Check whether TitleTextPosition is readable and writable.")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Popup.TitleTextPosition A")]\r
-        [Property("SPEC_URL", "-")]\r
-        [Property("CRITERIA", "PRW")]\r
-        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]\r
-        public void TitleTextPosition_SET_GET_VALUE()\r
-        {\r
-            /* TEST CODE */\r
-            var popup = new Components.Popup();\r
-            Assert.IsNotNull(popup, "Should be not Null!");\r
-            Assert.IsInstanceOf<Components.Popup>(popup, "Should be equal!");\r
-\r
-            popup.TitleTextPosition = new Position(10, 10);\r
-\r
-            Assert.AreEqual(10, popup.TitleTextPosition.X, "Should be equal");\r
-            Assert.AreEqual(10, popup.TitleTextPosition.Y, "Should be equal");\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test TitleHeight. Check whether TitleHeight is readable and writable.")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Popup.TitleHeight A")]\r
-        [Property("SPEC_URL", "-")]\r
-        [Property("CRITERIA", "PRW")]\r
-        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]\r
-        public void TitleHeight_SET_GET_VALUE()\r
-        {\r
-            /* TEST CODE */\r
-            var popup = new Components.Popup();\r
-            Assert.IsNotNull(popup, "Should be not Null!");\r
-            Assert.IsInstanceOf<Components.Popup>(popup, "Should be equal!");\r
-\r
-            popup.TitleHeight = 10;\r
-            Assert.AreEqual(10, popup.TitleHeight, "Should be equals to the set value of TitleHeight");\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test ButtonHeight. Check whether ButtonHeight is readable and writable.")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Popup.ButtonHeight A")]\r
-        [Property("SPEC_URL", "-")]\r
-        [Property("CRITERIA", "PRW")]\r
-        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]\r
-        public void ButtonHeight_SET_GET_VALUE()\r
-        {\r
-            /* TEST CODE */\r
-            var popup = new Components.Popup();\r
-            Assert.IsNotNull(popup, "Should be not Null!");\r
-            Assert.IsInstanceOf<Components.Popup>(popup, "Should be equal!");\r
-\r
-            popup.ButtonHeight = 10;\r
-            Assert.AreEqual(10, popup.ButtonHeight, "Should be equals to the set value of ButtonHeight");\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test ButtonTextPointSize. Check whether ButtonTextPointSize is readable and writable.")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Popup.ButtonTextPointSize A")]\r
-        [Property("SPEC_URL", "-")]\r
-        [Property("CRITERIA", "PRW")]\r
-        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]\r
-        public void ButtonTextPointSize_SET_GET_VALUE()\r
-        {\r
-            /* TEST CODE */\r
-            var popup = new Components.Popup();\r
-            Assert.IsNotNull(popup, "Should be not Null!");\r
-            Assert.IsInstanceOf<Components.Popup>(popup, "Should be equal!");\r
-\r
-            popup.ButtonTextPointSize = 10.0f;\r
-            Assert.AreEqual(10.0f, popup.ButtonTextPointSize, "Should be equals to the set value of ButtonTextPointSize");\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test ButtonFontFamily. Check whether ButtonFontFamily is readable and writable.")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Popup.ButtonFontFamily A")]\r
-        [Property("SPEC_URL", "-")]\r
-        [Property("CRITERIA", "PRW")]\r
-        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]\r
-        public void ButtonFontFamily_SET_GET_VALUE()\r
-        {\r
-            /* TEST CODE */\r
-            var popup = new Components.Popup();\r
-            Assert.IsNotNull(popup, "Should be not Null!");\r
-            Assert.IsInstanceOf<Components.Popup>(popup, "Should be equal!");\r
-\r
-            popup.ButtonFontFamily = "SamsungOne 500";\r
-            Assert.AreEqual("SamsungOne 500", popup.ButtonFontFamily, "Should be equals to the set value of ButtonFontFamily");\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test ButtonTextAlignment. Check whether ButtonTextAlignment is readable and writable.")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Popup.ButtonTextAlignment A")]\r
-        [Property("SPEC_URL", "-")]\r
-        [Property("CRITERIA", "PRW")]\r
-        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]\r
-        public void ButtonTextAlignment_SET_GET_VALUE()\r
-        {\r
-            /* TEST CODE */\r
-            var popup = new Components.Popup();\r
-            Assert.IsNotNull(popup, "Should be not Null!");\r
-            Assert.IsInstanceOf<Components.Popup>(popup, "Should be equal!");\r
-\r
-            popup.ButtonTextAlignment = HorizontalAlignment.Begin;\r
-            Assert.AreEqual(HorizontalAlignment.Begin, popup.ButtonTextAlignment, "Should be equal");\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test ButtonTextColor. Check whether ButtonTextColor is readable and writable.")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Popup.ButtonTextColor A")]\r
-        [Property("SPEC_URL", "-")]\r
-        [Property("CRITERIA", "PRW")]\r
-        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]\r
-        public void ButtonTextColor_SET_GET_VALUE()\r
-        {\r
-            /* TEST CODE */\r
-            var popup = new Components.Popup();\r
-            Assert.IsNotNull(popup, "Should be not Null!");\r
-            Assert.IsInstanceOf<Components.Popup>(popup, "Should be equal!");\r
-\r
-            var textColor = new Color(0.0f, 0.0f, 1.0f, 0.0f);\r
-            Assert.IsNotNull(textColor, "Should be not Null!");\r
-            Assert.IsInstanceOf<Color>(textColor, "Should be equal!");\r
-            popup.ButtonTextColor = textColor;\r
-\r
-            Assert.AreEqual(textColor.R, popup.ButtonTextColor.R, "Should be equal");\r
-            Assert.AreEqual(textColor.G, popup.ButtonTextColor.G, "Should be equal");\r
-            Assert.AreEqual(textColor.B, popup.ButtonTextColor.B, "Should be equal");\r
-            Assert.AreEqual(textColor.A, popup.ButtonTextColor.A, "Should be equal");\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test SetButtonText. Check it has been triggered")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Popup.SetButtonText M")]\r
-        [Property("SPEC_URL", "-")]\r
-        [Property("CRITERIA", "MCST")]\r
-        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]\r
-        public void SetButtonText_CHECK_VALUE()\r
-        {\r
-            /* TEST CODE */\r
-            try\r
-            {\r
-                Popup popup = new Popup();\r
-                Assert.IsNotNull(popup, "Should be not Null!");\r
-                Assert.IsInstanceOf<Components.Popup>(popup, "Should be equal!");\r
-                popup.SetButtonText(0, "YES");\r
-            }\r
-            catch (Exception e)\r
-            {\r
-                Tizen.Log.Error(TAG, "Caught Exception" + e.ToString());\r
-                LogUtils.Write(LogUtils.DEBUG, LogUtils.TAG, "Caught Exception" + e.ToString());\r
-                Assert.Fail("Caught Exception" + e.ToString());\r
-            }\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test Dispose, try to dispose the Popup.")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Popup.Dispose M")]\r
-        [Property("SPEC_URL", "-")]\r
-        [Property("CRITERIA", "MCST")]\r
-        [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]\r
-        public void Dispose_TEST()\r
-        {\r
-            /* TEST CODE */\r
-            try\r
-            {\r
-                Popup popup = new Popup();\r
-                Assert.IsNotNull(popup, "Should be not Null!");\r
-                Assert.IsInstanceOf<Components.Popup>(popup, "Should be equal!");\r
-                popup.Dispose();\r
-            }\r
-            catch (Exception e)\r
-            {\r
-                Tizen.Log.Error(TAG, "Caught Exception" + e.ToString());\r
-                LogUtils.Write(LogUtils.DEBUG, LogUtils.TAG, "Caught Exception" + e.ToString());\r
-                Assert.Fail("Caught Exception" + e.ToString());\r
-            }\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test AddButton. Check whether AddButton works or not.")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Popup.AddButton M")]\r
-        [Property("SPEC_URL", " - ")]\r
-        [Property("CRITERIA", "MR")]\r
-        [Property("COVPARAM", "string, string")]\r
-        [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]\r
-        public void AddButton_WITH_STRING_STRING()\r
-        {\r
-            try\r
-            {\r
-                var popup = new Popup();\r
-                var style = new ButtonStyle();\r
-                popup.AddButton("button1", "button");\r
-            }\r
-            catch (Exception e)\r
-            {\r
-                Assert.Fail("Caught Exception" + e.ToString());\r
-            }\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test AddButton. Check whether AddButton works or not.")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Popup.AddButton M")]\r
-        [Property("SPEC_URL", " - ")]\r
-        [Property("CRITERIA", "MR")]\r
-        [Property("COVPARAM", "string, ButtonStyle")]\r
-        [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]\r
-        public void AddButton_WITH_STRING_STYLE()\r
-        {\r
-            try\r
-            {\r
-                var popup = new Popup();\r
-                var style = new ButtonStyle();\r
-                popup.AddButton("button1", style);\r
-            }\r
-            catch (Exception e)\r
-            {\r
-                Assert.Fail("Caught Exception" + e.ToString());\r
-            }\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test ApplyStyle. Check whether ApplyStyle works or not.")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Popup.ApplyStyle M")]\r
-        [Property("SPEC_URL", " - ")]\r
-        [Property("CRITERIA", "MR")]\r
-        [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]\r
-        public void ApplyStyle_NO_RETURN_VALUE()\r
-        {\r
-            try\r
-            {\r
-                var popup = new Popup();\r
-                var style = new ButtonStyle();\r
-                popup.ApplyStyle(style);\r
-            }\r
-            catch (Exception e)\r
-            {\r
-                Assert.Fail("Caught Exception" + e.ToString());\r
-            }\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test GetViewStyle. Check whether GetViewStyle works or not.")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Popup.GetViewStyle M")]\r
-        [Property("SPEC_URL", " - ")]\r
-        [Property("CRITERIA", "MR")]\r
-        [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]\r
-        public void GetViewStyle_CHECK_RETURN_VALUE()\r
-        {\r
-            try\r
-            {\r
-                _flagGetViewStyle = false;\r
-                var popup = new MyPopup();\r
-                var style = popup.Style;\r
-                Assert.IsNotNull(style, "Should be not null");\r
-                Assert.IsTrue(_flagGetViewStyle, "Should be true!");\r
-            }\r
-            catch (Exception e)\r
-            {\r
-                Assert.Fail("Caught Exception" + e.ToString());\r
-            }\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test OnThemeChangedEvent. Check whether OnThemeChangedEvent works or not.")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Popup.OnThemeChangedEvent M")]\r
-        [Property("SPEC_URL", " - ")]\r
-        [Property("CRITERIA", "MR")]\r
-        [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]\r
-        public void OnThemeChangedEvent_CHECK_RETURN_VALUE()\r
-        {\r
-            try\r
-            {\r
-                _flagOnThemeChangedEvent = false;\r
-                StyleManager.Instance.Theme = "Family";\r
-                var popup = new MyPopup();\r
-                StyleManager.Instance.Theme = "Food";\r
-                Assert.IsNotNull(popup, "Should be not null");\r
-                Assert.IsTrue(_flagOnThemeChangedEvent, "Should be true!");\r
-            }\r
-            catch (Exception e)\r
-            {\r
-                Assert.Fail("Caught Exception" + e.ToString());\r
-            }\r
-        }\r
-\r
-        public class MyPopup : Popup\r
-        {\r
-            public MyPopup () : base() {}\r
-\r
-            protected override ViewStyle GetViewStyle()\r
-            {\r
-                _flagGetViewStyle = true;\r
-                return base.GetViewStyle();\r
-            }\r
-\r
-            protected override void OnThemeChangedEvent(object sender, StyleManager.ThemeChangeEventArgs e)\r
-            {\r
-                _flagOnThemeChangedEvent = true;\r
-            }\r
-        }\r
-\r
-        public class DefaultPopupStyle : StyleBase\r
-        {\r
-            protected override ViewStyle GetViewStyle()\r
-            {\r
-                return new PopupStyle();\r
-            }\r
-        }\r
-    }\r
-}\r
+using NUnit.Framework;
+using NUnit.Framework.TUnit;
+using System;
+using Tizen.NUI;
+using Tizen.NUI.Components;
+using Tizen.NUI.BaseComponents;
+using System.Runtime.InteropServices;
+using System.Threading.Tasks;
+using Tizen.NUI.Components.Test;
+
+namespace Tizen.NUI.Components.Tests
+{
+    [TestFixture]
+    [Description("Tizen.NUI.Components.Popup Tests")]
+    public class PopupTests
+    {
+        private const string TAG = "Components";
+        private string _image_path = Tizen.Applications.Application.Current.DirectoryInfo.Resource + "picture.png";
+        private string _path = Tizen.Applications.Application.Current.DirectoryInfo.Resource;
+        private static bool _flagOnThemeChangedEvent = false;
+
+        [SetUp]
+        public void Init()
+        {
+            Tizen.Log.Info(TAG, "Init() is called!");
+        }
+
+        [TearDown]
+        public void Destroy()
+        {
+            Tizen.Log.Info(TAG, "Destroy() is called!");
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test Popup empty constructor. Check it has been triggered")]
+        [Property("SPEC", "Tizen.NUI.Components.Popup.Popup C")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "CONSTR")]
+        [Property("COVPARAM", "")]
+        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]
+        public void Popup_CHECK_VALUE()
+        {
+            /* TEST CODE */
+            var popup = new Components.Popup();
+            Assert.IsNotNull(popup, "Should be not Null!");
+            Assert.IsInstanceOf<Components.Popup>(popup, "Should be equal!");
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test Popup constructor using string. Check whether Popup is successfully created or not.")]
+        [Property("SPEC", "Tizen.NUI.Components.Popup.Popup C")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "CONSTR")]
+        [Property("COVPARAM", "string")]
+        [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]
+        public void Popup_INIT_WITH_STRING()
+        {
+            /* TEST CODE */
+            StyleManager.Instance.Theme = "default";
+            StyleManager.Instance.RegisterStyle("defaultPopup", "default", typeof(DefaultPopupStyle));
+            var popup = new Popup("defaultPopup");
+            Assert.IsNotNull(popup, "Should be not null!");
+            Assert.IsInstanceOf<Popup>(popup, "Should be an instance of Popup!");
+        }
+
+        [Test]
+        [Category("P2")]
+        [Description("Check exception when constructing a Popup with nonexistent style")]
+        [Property("SPEC", "Tizen.NUI.Components.Popup.Popup C")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "CONSTX")]
+        [Property("COVPARAM", "string")]
+        [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]
+        public void Popup_INIT_WITH_STRING_Exception()
+        {
+            /* TEST CODE */
+            try
+            {
+                var popup = new Popup("defaultPopupX");
+                Assert.Fail("Should throw the Exception: There is no style of defaultPopupX !");
+            }
+            catch(InvalidOperationException e)
+            {
+                Assert.Pass("InvalidOperationException: passed!");
+            }
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test Popup constructor using style. Check whether Popup is successfully created or not.")]
+        [Property("SPEC", "Tizen.NUI.Components.Popup.Popup C")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "CONSTR")]
+        [Property("COVPARAM", "PopupStyle")]
+        [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]
+        public void Popup_INIT_WITH_STYLE()
+        {
+            /* TEST CODE */
+            var style = new PopupStyle();
+            Assert.IsNotNull(style, "Should be not null!");
+            Assert.IsInstanceOf<PopupStyle>(style, "Should be an instance of PopupStyle!");
+
+            var popup = new Popup(style);
+            Assert.IsNotNull(popup, "Should be not null!");
+            Assert.IsInstanceOf<Popup>(popup, "Should be an instance of Popup!");
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test Style. Check whether Style is readable.")]
+        [Property("SPEC", "Tizen.NUI.Components.Popup.Style A")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "PRO")]
+        [Property("AUTHOR", "Xianbing teng, xb.teng@samsung.com")]
+        public void Style_CHECK_GET_VALUE()
+        {
+            /* TEST CODE */
+            var popup = new Popup();
+            Assert.IsNotNull(popup, "Should be not null");
+            Assert.IsInstanceOf<Popup>(popup, "Should be an instance of Popup!");
+
+            var style = popup.Style;
+            Assert.IsNotNull(style, "Should be not null");
+            Assert.IsInstanceOf<PopupStyle>(style, "Should be an instance of PopupStyle!");
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test TitleText. Check whether TitleText is readable and writable.")]
+        [Property("SPEC", "Tizen.NUI.Components.Popup.TitleText A")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "PRW")]
+        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]
+        public void TitleText_SET_GET_VALUE()
+        {
+            /* TEST CODE */
+            var popup = new Components.Popup();
+            Assert.IsNotNull(popup, "Should be not Null!");
+            Assert.IsInstanceOf<Components.Popup>(popup, "Should be equal!");
+
+            popup.TitleText = "Test TitleText";
+            Assert.AreEqual("Test TitleText", popup.TitleText, "Should be equals to the set value of TitleText");
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test ButtonCount. Check whether ButtonCount is readable and writable.")]
+        [Property("SPEC", "Tizen.NUI.Components.Popup.ButtonCount A")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "PRW")]
+        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]
+        public void ButtonCount_SET_GET_VALUE()
+        {
+            /* TEST CODE */
+            var popup = new Components.Popup();
+            Assert.IsNotNull(popup, "Should be not Null!");
+            Assert.IsInstanceOf<Components.Popup>(popup, "Should be equal!");
+
+            popup.ButtonCount = 2;
+            Assert.AreEqual(2, popup.ButtonCount, "Should be equals to the set value of ButtonCount");
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test ContentView. Check whether ContentView is readable.")]
+        [Property("SPEC", "Tizen.NUI.Components.Popup.ContentView A")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "PRO")]
+        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]
+        public void ContentView_GET_VALUE()
+        {
+            /* TEST CODE */
+            var popup = new Components.Popup();
+            Assert.IsNotNull(popup.ContentView, "Should be equals!");
+            Assert.IsInstanceOf<BaseComponents.View>(popup.ContentView, "Should be an instance of view!");
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test TitlePointSize. Check whether TitlePointSize is readable and writable.")]
+        [Property("SPEC", "Tizen.NUI.Components.Popup.TitlePointSize A")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "PRW")]
+        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]
+        public void TitlePointSize_SET_GET_VALUE()
+        {
+            /* TEST CODE */
+            var popup = new Components.Popup();
+            Assert.IsNotNull(popup, "Should be not Null!");
+            Assert.IsInstanceOf<Components.Popup>(popup, "Should be equal!");
+
+            popup.TitlePointSize = 10.0f;
+            Assert.AreEqual(10.0f, popup.TitlePointSize, "Should be equals to the set value of TitlePointSize");
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test TitleTextColor. Check whether TitleTextColor is readable and writable.")]
+        [Property("SPEC", "Tizen.NUI.Components.Popup.TitleTextColor A")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "PRW")]
+        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]
+        public void TitleTextColor_SET_GET_VALUE()
+        {
+            /* TEST CODE */
+            var popup = new Components.Popup();
+            Assert.IsNotNull(popup, "Should be not Null!");
+            Assert.IsInstanceOf<Components.Popup>(popup, "Should be equal!");
+
+            var color = new Color(1.0f, 0.0f, 0.0f, 1.0f);
+            Assert.IsNotNull(color, "Should be not Null!");
+            Assert.IsInstanceOf<Color>(color, "Should be equal!");
+            popup.TitleTextColor = color;
+
+            Assert.AreEqual(color.R, popup.TitleTextColor.R, "Should be equals to the color.R set");
+            Assert.AreEqual(color.G, popup.TitleTextColor.G, "Should be equals to the color.G set");
+            Assert.AreEqual(color.B, popup.TitleTextColor.B, "Should be equals to the color.B set");
+            Assert.AreEqual(color.A, popup.TitleTextColor.A, "Should be equals to the color.A set");
+
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test TitleTextHorizontalAlignment. Check whether TitleTextHorizontalAlignment is readable and writable.")]
+        [Property("SPEC", "Tizen.NUI.Components.Popup.TitleTextHorizontalAlignment A")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "PRW")]
+        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]
+        public void TitleTextHorizontalAlignment_SET_GET_VALUE()
+        {
+            /* TEST CODE */
+            var popup = new Components.Popup();
+            Assert.IsNotNull(popup, "Should be not Null!");
+            Assert.IsInstanceOf<Components.Popup>(popup, "Should be equal!");
+
+            popup.TitleTextHorizontalAlignment = HorizontalAlignment.Begin;
+            Assert.AreEqual(HorizontalAlignment.Begin, popup.TitleTextHorizontalAlignment, "Should be equals to the set value of TitleTextHorizontalAlignment");
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test TitleTextPosition. Check whether TitleTextPosition is readable and writable.")]
+        [Property("SPEC", "Tizen.NUI.Components.Popup.TitleTextPosition A")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "PRW")]
+        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]
+        public void TitleTextPosition_SET_GET_VALUE()
+        {
+            /* TEST CODE */
+            var popup = new Components.Popup();
+            Assert.IsNotNull(popup, "Should be not Null!");
+            Assert.IsInstanceOf<Components.Popup>(popup, "Should be equal!");
+
+            popup.TitleTextPosition = new Position(10, 10);
+
+            Assert.AreEqual(10, popup.TitleTextPosition.X, "Should be equal");
+            Assert.AreEqual(10, popup.TitleTextPosition.Y, "Should be equal");
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test TitleHeight. Check whether TitleHeight is readable and writable.")]
+        [Property("SPEC", "Tizen.NUI.Components.Popup.TitleHeight A")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "PRW")]
+        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]
+        public void TitleHeight_SET_GET_VALUE()
+        {
+            /* TEST CODE */
+            var popup = new Components.Popup();
+            Assert.IsNotNull(popup, "Should be not Null!");
+            Assert.IsInstanceOf<Components.Popup>(popup, "Should be equal!");
+
+            popup.TitleHeight = 10;
+            Assert.AreEqual(10, popup.TitleHeight, "Should be equals to the set value of TitleHeight");
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test ButtonHeight. Check whether ButtonHeight is readable and writable.")]
+        [Property("SPEC", "Tizen.NUI.Components.Popup.ButtonHeight A")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "PRW")]
+        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]
+        public void ButtonHeight_SET_GET_VALUE()
+        {
+            /* TEST CODE */
+            var popup = new Components.Popup();
+            Assert.IsNotNull(popup, "Should be not Null!");
+            Assert.IsInstanceOf<Components.Popup>(popup, "Should be equal!");
+
+            popup.ButtonHeight = 10;
+            Assert.AreEqual(10, popup.ButtonHeight, "Should be equals to the set value of ButtonHeight");
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test ButtonTextPointSize. Check whether ButtonTextPointSize is readable and writable.")]
+        [Property("SPEC", "Tizen.NUI.Components.Popup.ButtonTextPointSize A")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "PRW")]
+        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]
+        public void ButtonTextPointSize_SET_GET_VALUE()
+        {
+            /* TEST CODE */
+            var popup = new Components.Popup();
+            Assert.IsNotNull(popup, "Should be not Null!");
+            Assert.IsInstanceOf<Components.Popup>(popup, "Should be equal!");
+
+            popup.ButtonTextPointSize = 10.0f;
+            Assert.AreEqual(10.0f, popup.ButtonTextPointSize, "Should be equals to the set value of ButtonTextPointSize");
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test ButtonFontFamily. Check whether ButtonFontFamily is readable and writable.")]
+        [Property("SPEC", "Tizen.NUI.Components.Popup.ButtonFontFamily A")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "PRW")]
+        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]
+        public void ButtonFontFamily_SET_GET_VALUE()
+        {
+            /* TEST CODE */
+            var popup = new Components.Popup();
+            Assert.IsNotNull(popup, "Should be not Null!");
+            Assert.IsInstanceOf<Components.Popup>(popup, "Should be equal!");
+
+            popup.ButtonFontFamily = "SamsungOne 500";
+            Assert.AreEqual("SamsungOne 500", popup.ButtonFontFamily, "Should be equals to the set value of ButtonFontFamily");
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test ButtonTextAlignment. Check whether ButtonTextAlignment is readable and writable.")]
+        [Property("SPEC", "Tizen.NUI.Components.Popup.ButtonTextAlignment A")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "PRW")]
+        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]
+        public void ButtonTextAlignment_SET_GET_VALUE()
+        {
+            /* TEST CODE */
+            var popup = new Components.Popup();
+            Assert.IsNotNull(popup, "Should be not Null!");
+            Assert.IsInstanceOf<Components.Popup>(popup, "Should be equal!");
+
+            popup.ButtonTextAlignment = HorizontalAlignment.Begin;
+            Assert.AreEqual(HorizontalAlignment.Begin, popup.ButtonTextAlignment, "Should be equal");
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test ButtonTextColor. Check whether ButtonTextColor is readable and writable.")]
+        [Property("SPEC", "Tizen.NUI.Components.Popup.ButtonTextColor A")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "PRW")]
+        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]
+        public void ButtonTextColor_SET_GET_VALUE()
+        {
+            /* TEST CODE */
+            var popup = new Components.Popup();
+            Assert.IsNotNull(popup, "Should be not Null!");
+            Assert.IsInstanceOf<Components.Popup>(popup, "Should be equal!");
+
+            var textColor = new Color(0.0f, 0.0f, 1.0f, 0.0f);
+            Assert.IsNotNull(textColor, "Should be not Null!");
+            Assert.IsInstanceOf<Color>(textColor, "Should be equal!");
+            popup.ButtonTextColor = textColor;
+
+            Assert.AreEqual(textColor.R, popup.ButtonTextColor.R, "Should be equal");
+            Assert.AreEqual(textColor.G, popup.ButtonTextColor.G, "Should be equal");
+            Assert.AreEqual(textColor.B, popup.ButtonTextColor.B, "Should be equal");
+            Assert.AreEqual(textColor.A, popup.ButtonTextColor.A, "Should be equal");
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test SetButtonText. Check it has been triggered")]
+        [Property("SPEC", "Tizen.NUI.Components.Popup.SetButtonText M")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "MCST")]
+        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]
+        public void SetButtonText_CHECK_VALUE()
+        {
+            /* TEST CODE */
+            try
+            {
+                Popup popup = new Popup();
+                Assert.IsNotNull(popup, "Should be not Null!");
+                Assert.IsInstanceOf<Components.Popup>(popup, "Should be equal!");
+                popup.SetButtonText(0, "YES");
+            }
+            catch (Exception e)
+            {
+                Tizen.Log.Error(TAG, "Caught Exception" + e.ToString());
+                LogUtils.Write(LogUtils.DEBUG, LogUtils.TAG, "Caught Exception" + e.ToString());
+                Assert.Fail("Caught Exception" + e.ToString());
+            }
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test Dispose, try to dispose the Popup.")]
+        [Property("SPEC", "Tizen.NUI.Components.Popup.Dispose M")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "MCST")]
+        [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]
+        public void Dispose_TEST()
+        {
+            /* TEST CODE */
+            try
+            {
+                Popup popup = new Popup();
+                Assert.IsNotNull(popup, "Should be not Null!");
+                Assert.IsInstanceOf<Components.Popup>(popup, "Should be equal!");
+                popup.Dispose();
+            }
+            catch (Exception e)
+            {
+                Tizen.Log.Error(TAG, "Caught Exception" + e.ToString());
+                LogUtils.Write(LogUtils.DEBUG, LogUtils.TAG, "Caught Exception" + e.ToString());
+                Assert.Fail("Caught Exception" + e.ToString());
+            }
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test AddButton. Check whether AddButton works or not.")]
+        [Property("SPEC", "Tizen.NUI.Components.Popup.AddButton M")]
+        [Property("SPEC_URL", " - ")]
+        [Property("CRITERIA", "MR")]
+        [Property("COVPARAM", "string, string")]
+        [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]
+        public void AddButton_WITH_STRING_STRING()
+        {
+            try
+            {
+                var popup = new Popup();
+                var style = new ButtonStyle();
+                popup.AddButton("button1", "button");
+            }
+            catch (Exception e)
+            {
+                Assert.Fail("Caught Exception" + e.ToString());
+            }
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test AddButton. Check whether AddButton works or not.")]
+        [Property("SPEC", "Tizen.NUI.Components.Popup.AddButton M")]
+        [Property("SPEC_URL", " - ")]
+        [Property("CRITERIA", "MR")]
+        [Property("COVPARAM", "string, ButtonStyle")]
+        [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]
+        public void AddButton_WITH_STRING_STYLE()
+        {
+            try
+            {
+                var popup = new Popup();
+                var style = new ButtonStyle();
+                popup.AddButton("button1", style);
+            }
+            catch (Exception e)
+            {
+                Assert.Fail("Caught Exception" + e.ToString());
+            }
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test ApplyStyle. Check whether ApplyStyle works or not.")]
+        [Property("SPEC", "Tizen.NUI.Components.Popup.ApplyStyle M")]
+        [Property("SPEC_URL", " - ")]
+        [Property("CRITERIA", "MR")]
+        [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]
+        public void ApplyStyle_NO_RETURN_VALUE()
+        {
+            try
+            {
+                var popup = new Popup();
+                var style = new ButtonStyle();
+                popup.ApplyStyle(style);
+            }
+            catch (Exception e)
+            {
+                Assert.Fail("Caught Exception" + e.ToString());
+            }
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test CreateViewStyle. Check whether CreateViewStyle works or not.")]
+        [Property("SPEC", "Tizen.NUI.Components.Popup.CreateViewStyle M")]
+        [Property("SPEC_URL", " - ")]
+        [Property("CRITERIA", "MR")]
+        [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]
+        public void CreateViewStyle_CHECK_RETURN_VALUE()
+        {
+            try
+            {
+                var popup = new MyPopup();
+                ViewStyle style = popup.CreateMyViewStyle();
+                Assert.IsNotNull(style, "Should be not null");
+            }
+            catch (Exception e)
+            {
+                Assert.Fail("Caught Exception" + e.ToString());
+            }
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test OnThemeChangedEvent. Check whether OnThemeChangedEvent works or not.")]
+        [Property("SPEC", "Tizen.NUI.Components.Popup.OnThemeChangedEvent M")]
+        [Property("SPEC_URL", " - ")]
+        [Property("CRITERIA", "MR")]
+        [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]
+        public void OnThemeChangedEvent_CHECK_RETURN_VALUE()
+        {
+            try
+            {
+                _flagOnThemeChangedEvent = false;
+                StyleManager.Instance.Theme = "Family";
+                var popup = new MyPopup();
+                StyleManager.Instance.Theme = "Food";
+                Assert.IsNotNull(popup, "Should be not null");
+                Assert.IsTrue(_flagOnThemeChangedEvent, "Should be true!");
+            }
+            catch (Exception e)
+            {
+                Assert.Fail("Caught Exception" + e.ToString());
+            }
+        }
+
+        public class MyPopup : Popup
+        {
+            public MyPopup() : base() {}\r
+\r
+            public ViewStyle CreateMyViewStyle()
+            {
+                return base.CreateViewStyle();
+            }
+
+            protected override void OnThemeChangedEvent(object sender, StyleManager.ThemeChangeEventArgs e)
+            {
+                _flagOnThemeChangedEvent = true;
+            }
+        }
+
+        public class DefaultPopupStyle : StyleBase
+        {
+            protected override ViewStyle GetViewStyle()
+            {
+                return new PopupStyle();
+            }
+        }
+    }
+}
old mode 100755 (executable)
new mode 100644 (file)
index 919b9b6..b1fa406
@@ -16,7 +16,6 @@ namespace Tizen.NUI.Components.Tests
     {
         private const string TAG = "Components";
         private string _image_path = Tizen.Applications.Application.Current.DirectoryInfo.Resource + "Tizen.NUI.Components.Tests.png";
-        private static bool _flagGetViewStyle = false;
         private static bool _flagOnThemeChangedEvent = false;
 
         [SetUp]
@@ -401,20 +400,18 @@ namespace Tizen.NUI.Components.Tests
 
         [Test]
         [Category("P1")]
-        [Description("Test GetViewStyle. Check whether GetViewStyle works or not.")]
-        [Property("SPEC", "Tizen.NUI.Components.Progress.GetViewStyle M")]
+        [Description("Test GetViewStyle. Check whether CreateViewStyle works or not.")]
+        [Property("SPEC", "Tizen.NUI.Components.Progress.CreateViewStyle M")]
         [Property("SPEC_URL", " - ")]
         [Property("CRITERIA", "MR")]
         [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]
-        public void GetViewStyle_CHECK_RETURN_VALUE()
+        public void CreateViewStyle_CHECK_RETURN_VALUE()
         {
             try
             {
-                _flagGetViewStyle = false;
                 var progress = new MyProgress();
-                var style = progress.Style;
+                ViewStyle style = progress.CreateMyViewStyle();
                 Assert.IsNotNull(style, "Should be not null");
-                Assert.IsTrue(_flagGetViewStyle, "Should be true!");
             }
             catch (Exception e)
             {
@@ -449,17 +446,16 @@ namespace Tizen.NUI.Components.Tests
         public class MyProgress : Progress
         {
             public MyProgress() : base()
-            { }
-
-            public void _ChangeImageState(ProgressStatusType statusType)
+            { }\r
+\r
+            public ViewStyle CreateMyViewStyle()
             {
-                base.ChangeImageState(statusType);
+                return base.CreateViewStyle();
             }
 
-            protected override ViewStyle GetViewStyle()
+            public void _ChangeImageState(ProgressStatusType statusType)
             {
-                _flagGetViewStyle = true;
-                return base.GetViewStyle();
+                base.ChangeImageState(statusType);
             }
 
             protected override void OnThemeChangedEvent(object sender, StyleManager.ThemeChangeEventArgs e)
old mode 100755 (executable)
new mode 100644 (file)
index ae8ad4c..5decea9
@@ -15,7 +15,6 @@ namespace Tizen.NUI.Components.Tests
     {\r
         private const string TAG = "NUI.Components";\r
         private string _trackImageUrl = "";\r
-        private static bool _flagGetViewStyle = false;\r
         private static bool _flagOnThemeChangedEvent = false;\r
 \r
         [SetUp]\r
@@ -407,20 +406,18 @@ namespace Tizen.NUI.Components.Tests
 \r
         [Test]\r
         [Category("P1")]\r
-        [Description("Test GetViewStyle. Check whether GetViewStyle works or not.")]\r
-        [Property("SPEC", "Tizen.NUI.Components.ScrollBar.GetViewStyle M")]\r
+        [Description("Test GetViewStyle. Check whether CreateViewStyle works or not.")]\r
+        [Property("SPEC", "Tizen.NUI.Components.ScrollBar.CreateViewStyle M")]\r
         [Property("SPEC_URL", " - ")]\r
         [Property("CRITERIA", "MR")]\r
         [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]\r
-        public void GetViewStyle_CHECK_RETURN_VALUE()\r
+        public void CreateViewStyle_CHECK_RETURN_VALUE()\r
         {\r
             try\r
             {\r
-                _flagGetViewStyle = false;\r
                 var scrollBar = new MyScrollBar();\r
-                var style = scrollBar.Style;\r
+                ViewStyle style = scrollBar.CreateMyViewStyle();\r
                 Assert.IsNotNull(style, "Should be not null");\r
-                Assert.IsTrue(_flagGetViewStyle, "Should be true!");\r
             }\r
             catch (Exception e)\r
             {\r
@@ -456,10 +453,9 @@ namespace Tizen.NUI.Components.Tests
         {\r
             public MyScrollBar() : base() {}\r
 \r
-            protected override ViewStyle GetViewStyle()\r
+            public ViewStyle CreateMyViewStyle()\r
             {\r
-                _flagGetViewStyle = true;\r
-                return base.GetViewStyle();\r
+                return base.CreateViewStyle();\r
             }\r
 \r
             protected override void OnThemeChangedEvent(object sender, StyleManager.ThemeChangeEventArgs e)\r
old mode 100755 (executable)
new mode 100644 (file)
index b5f33ff..1655b40
@@ -13,7 +13,6 @@ namespace Tizen.NUI.Components.Tests
     {
         private const string TAG = "TCT";
         private string _image_path = Tizen.Applications.Application.Current.DirectoryInfo.Resource + "picture.png";
-        private static bool _flagGetViewStyle = false;
         private static bool _flagOnThemeChangedEvent = false;
 
         public SliderTests()
@@ -541,24 +540,22 @@ namespace Tizen.NUI.Components.Tests
             {
                 Assert.Fail("Caught Exception" + e.ToString());
             }
-        }
-
+        }\r
+\r
         [Test]
         [Category("P1")]
-        [Description("Test GetViewStyle. Check whether GetViewStyle works or not.")]
-        [Property("SPEC", "Tizen.NUI.Components.Slider.GetViewStyle M")]
+        [Description("Test CreateViewStyle. Check whether CreateViewStyle works or not.")]
+        [Property("SPEC", "Tizen.NUI.Components.Slider.CreateViewStyle M")]
         [Property("SPEC_URL", " - ")]
         [Property("CRITERIA", "MR")]
         [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]
-        public void GetViewStyle_CHECK_RETURN_VALUE()
+        public void CreateViewStyle_CHECK_RETURN_VALUE()
         {
             try
             {
-                _flagGetViewStyle = false;
                 var slider = new MySlider();
-                var style = slider.Style;
+                ViewStyle style = slider.CreateMyViewStyle();
                 Assert.IsNotNull(style, "Should be not null");
-                Assert.IsTrue(_flagGetViewStyle, "Should be true!");
             }
             catch (Exception e)
             {
@@ -592,13 +589,12 @@ namespace Tizen.NUI.Components.Tests
 
         public class MySlider : Slider
         {
-            public MySlider () : base() {}
-
-            protected override ViewStyle GetViewStyle()
-            {
-                _flagGetViewStyle = true;
-                return base.GetViewStyle();
-            }
+            public MySlider() : base() {}\r
+\r
+            public ViewStyle CreateMyViewStyle()\r
+            {\r
+                return base.CreateViewStyle();\r
+            }\r
 
             protected override void OnThemeChangedEvent(object sender, StyleManager.ThemeChangeEventArgs e)
             {
old mode 100755 (executable)
new mode 100644 (file)
index dd08387..c392beb
-using NUnit.Framework;\r
-using NUnit.Framework.TUnit;\r
-using System;\r
-using Tizen.NUI;\r
-using Tizen.NUI.BaseComponents;\r
-using Tizen.NUI.Components;\r
-using System.Runtime.InteropServices;\r
-using System.Threading.Tasks;\r
-using Tizen.NUI.Components.Test;\r
+using NUnit.Framework;
+using NUnit.Framework.TUnit;
+using System;
+using Tizen.NUI;
+using Tizen.NUI.BaseComponents;
+using Tizen.NUI.Components;
+using System.Runtime.InteropServices;
+using System.Threading.Tasks;
+using Tizen.NUI.Components.Test;
+
+namespace Tizen.NUI.Components.Tests
+{
+    [TestFixture]
+    [Description("Tizen.NUI.Components.Switch Tests")]
+    public class SwitchTests
+    {
+        private const string TAG = "Components";
+        private string _image_path = Tizen.Applications.Application.Current.DirectoryInfo.Resource + "picture.png";
+        private static bool _flagOnThemeChangedEvent = false;
+
+        [SetUp]
+        public void Init()
+        {
+            Tizen.Log.Info(TAG, "Init() is called!");
+        }
+
+        [TearDown]
+        public void Destroy()
+        {
+            Tizen.Log.Info(TAG, "Destroy() is called!");
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test Switch empty constructor. Check it has been triggered")]
+        [Property("SPEC", "Tizen.NUI.Components.Switch.Switch C")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "CONSTR")]
+        [Property("COVPARAM", "")]
+        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]
+        public void Switch_CHECK_VALUE()
+        {
+            /* TEST CODE */
+            var _switch = new Switch();
+            Assert.IsNotNull(_switch, "Should be not null!");
+            Assert.IsInstanceOf<Switch>(_switch, "Should be an instance of Switch!");
+
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test Switch constructor using string. Check whether Switch is successfully created or not.")]
+        [Property("SPEC", "Tizen.NUI.Components.Switch.Switch C")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "CONSTR")]
+        [Property("COVPARAM", "string")]
+        [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]
+        public void Switch_INIT_WITH_STRING()
+        {
+            /* TEST CODE */
+            StyleManager.Instance.Theme = "default";
+            StyleManager.Instance.RegisterStyle("defaultSwitch", "default", typeof(DefaultSwitchStyle));
+            var switch1 = new Switch("defaultSwitch");
+            Assert.IsNotNull(switch1, "Should be not null!");
+            Assert.IsInstanceOf<Switch>(switch1, "Should be an instance of Switch!");
+        }
+
+        [Test]
+        [Category("P2")]
+        [Description("Check exception when constructing a Switch with nonexistent style.")]
+        [Property("SPEC", "Tizen.NUI.Components.Switch.Switch C")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "CONSTX")]
+        [Property("COVPARAM", "string")]
+        [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]
+        public void Switch_INIT_WITH_STRING_Exception()
+        {
+            /* TEST CODE */
+            try
+            {
+                var switch1 = new Switch("defaultSwitchX");
+                Assert.Fail("Should throw the Exception: There is no style of defaultSwitchX !");
+            }
+            catch(InvalidOperationException e)
+            {
+                Assert.Pass("InvalidOperationException: passed!");
+            }
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test Switch constructor using style. Check whether Switch is successfully created or not.")]
+        [Property("SPEC", "Tizen.NUI.Components.Switch.Switch C")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "CONSTR")]
+        [Property("COVPARAM", "SwitchStyle")]
+        [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]
+        public void Switch_INIT_WITH_STYLE()
+        {
+            /* TEST CODE */
+            var style = new SwitchStyle();
+            Assert.IsNotNull(style, "Should be not null!");
+            Assert.IsInstanceOf<SwitchStyle>(style, "Should be an instance of SwitchStyle!");
+
+            var _switch = new Switch(style);
+            Assert.IsNotNull(_switch, "Should be not null!");
+            Assert.IsInstanceOf<Switch>(_switch, "Should be an instance of Switch!");
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test Style. Check whether Style is readable.")]
+        [Property("SPEC", "Tizen.NUI.Components.Switch.Style A")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "PRO")]
+        [Property("AUTHOR", "Xianbing teng, xb.teng@samsung.com")]
+        public void Style_CHECK_GET_VALUE()
+        {
+            /* TEST CODE */
+            var _switch = new Switch();
+            Assert.IsNotNull(_switch, "Should be not null");
+            Assert.IsInstanceOf<Switch>(_switch, "Should be an instance of Switch!");
+
+            var style = _switch.Style;
+            Assert.IsNotNull(style, "Should be not null");
+            Assert.IsInstanceOf<SwitchStyle>(style, "Should be an instance of SwitchStyle!");
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test SwitchBackgroundImageURLSelector. Check whether SwitchBackgroundImageURLSelector is readable and writable.")]
+        [Property("SPEC", "Tizen.NUI.Components.Switch.SwitchBackgroundImageURLSelector A")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "PRW")]
+        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]
+        public void SwitchBackgroundImageURLSelector_SET_GET_VALUE()
+        {
+            /* TEST CODE */
+            var _switch = new Switch();
+            Assert.IsNotNull(_switch, "Should be not null!");
+            Assert.IsInstanceOf<Switch>(_switch, "Should be equal!");
+
+            StringSelector stringSelector = new StringSelector
+            {
+                Normal = _image_path,
+                Selected = _image_path,
+            };
+            Assert.IsNotNull(stringSelector, "Should be not null!");
+            Assert.IsInstanceOf<StringSelector>(stringSelector, "Should be equal!");
+
+            _switch.SwitchBackgroundImageURLSelector = stringSelector;
+            Assert.AreEqual(stringSelector.Normal, _switch.SwitchBackgroundImageURLSelector.Normal, "Should be equals to the set value of SwitchBackgroundImageURLSelector Normal");
+            Assert.AreEqual(stringSelector.Selected, _switch.SwitchBackgroundImageURLSelector.Selected, "Should be equals to the set value of SwitchBackgroundImageURLSelector Selected");
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test SwitchHandlerImageURL. Check whether SwitchHandlerImageURL is readable and writable.")]
+        [Property("SPEC", "Tizen.NUI.Components.Switch.SwitchHandlerImageURL A")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "PRW")]
+        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]
+        public void SwitchHandlerImageURL_SET_GET_VALUE()
+        {
+            /* TEST CODE */
+            var _switch = new Switch();
+            Assert.IsNotNull(_switch, "Should be not null!");
+            Assert.IsInstanceOf<Switch>(_switch, "Should be equal!");
+
+            _switch.SwitchHandlerImageURL = _image_path;
+            Assert.AreEqual(_image_path, _switch.SwitchHandlerImageURL, "Should be equals to the set value of SwitchHandlerImageURL");
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test SwitchHandlerImageURLSelector. Check whether SwitchHandlerImageURLSelector is readable and writable.")]
+        [Property("SPEC", "Tizen.NUI.Components.Switch.SwitchHandlerImageURLSelector A")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "PRW")]
+        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]
+        public void SwitchHandlerImageURLSelector_SET_GET_VALUE()
+        {
+            /* TEST CODE */
+            var _switch = new Switch();
+            Assert.IsNotNull(_switch, "Should be not null!");
+            Assert.IsInstanceOf<Switch>(_switch, "Should be equal!");
+
+            StringSelector stringSelector = new StringSelector
+            {
+                Normal = _image_path,
+                Selected = _image_path,
+            };
+            Assert.IsNotNull(stringSelector, "Should be not null!");
+            Assert.IsInstanceOf<StringSelector>(stringSelector, "Should be equal!");
+
+            _switch.SwitchHandlerImageURLSelector = stringSelector;
+            Assert.AreEqual(stringSelector.Normal, _switch.SwitchHandlerImageURLSelector.Normal, "Should be equals to the set value of SwitchHandlerImageURLSelector Normal");
+            Assert.AreEqual(stringSelector.Selected, _switch.SwitchHandlerImageURLSelector.Selected, "Should be equals to the set value of SwitchHandlerImageURLSelector Selected");
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test SwitchHandlerImageSize. Check whether SwitchHandlerImageSize is readable and writable.")]
+        [Property("SPEC", "Tizen.NUI.Components.Switch.SwitchHandlerImageSize A")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "PRW")]
+        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]
+        public void SwitchHandlerImageSize_SET_GET_VALUE()
+        {
+            /* TEST CODE */
+            var _switch = new Switch();
+            Assert.IsNotNull(_switch, "Should be not null!");
+            Assert.IsInstanceOf<Switch>(_switch, "Should be equal!");
+
+            _switch.SwitchHandlerImageSize = new Size(10, 10);
+            Assert.AreEqual(10, _switch.SwitchHandlerImageSize.Width, "Should be equals to the set value of SwitchHandlerImageSize2D.Width");
+            Assert.AreEqual(10, _switch.SwitchHandlerImageSize.Height, "Should be equals to the set value of SwitchHandlerImageSize2D.Height");
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test Dispose, try to dispose the Switch.")]
+        [Property("SPEC", "Tizen.NUI.Components.Switch.Dispose M")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "MCST")]
+        [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]
+        public void Dispose_TEST()
+        {
+            /* TEST CODE */
+            try
+            {
+                var mySwitch = new Switch();
+                Assert.IsNotNull(mySwitch, "Should be not null!");
+                Assert.IsInstanceOf<Switch>(mySwitch, "Should be equal!");
+
+                mySwitch.Dispose();
+            }
+            catch (Exception e)
+            {
+                Tizen.Log.Error(TAG, "Caught Exception" + e.ToString());
+                LogUtils.Write(LogUtils.DEBUG, LogUtils.TAG, "Caught Exception" + e.ToString());
+                Assert.Fail("Caught Exception" + e.ToString());
+            }
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test GetViewStyle. Check whether CreateViewStyle works or not.")]
+        [Property("SPEC", "Tizen.NUI.Components.Switch.CreateViewStyle M")]
+        [Property("SPEC_URL", " - ")]
+        [Property("CRITERIA", "MR")]
+        [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]
+        public void CreateViewStyle_CHECK_RETURN_VALUE()
+        {
+            try
+            {
+                var _switch = new MySwitch();
+                ViewStyle style = _switch.CreateMyViewStyle();
+                Assert.IsNotNull(style, "Should be not null");
+            }
+            catch (Exception e)
+            {
+                Assert.Fail("Caught Exception" + e.ToString());
+            }
+        }
+
+        [Test]
+        [Category("P1")]
+        [Description("Test OnThemeChangedEvent. Check whether OnThemeChangedEvent works or not.")]
+        [Property("SPEC", "Tizen.NUI.Components.Switch.OnThemeChangedEvent M")]
+        [Property("SPEC_URL", " - ")]
+        [Property("CRITERIA", "MR")]
+        [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]
+        public void OnThemeChangedEvent_CHECK_RETURN_VALUE()
+        {
+            try
+            {
+                _flagOnThemeChangedEvent = false;
+                StyleManager.Instance.Theme = "Family";
+                var _switch = new Switch();
+                StyleManager.Instance.Theme = "Food";
+                Assert.IsNotNull(_switch, "Should be not null");
+                Assert.IsTrue(_flagOnThemeChangedEvent, "Should be true!");
+            }
+            catch (Exception e)
+            {
+                Assert.Fail("Caught Exception" + e.ToString());
+            }
+        }
+
+        public class MySwitch : Switch
+        {
+            public MySwitch() : base() {}\r
 \r
-namespace Tizen.NUI.Components.Tests\r
-{\r
-    [TestFixture]\r
-    [Description("Tizen.NUI.Components.Switch Tests")]\r
-    public class SwitchTests\r
-    {\r
-        private const string TAG = "Components";\r
-        private string _image_path = Tizen.Applications.Application.Current.DirectoryInfo.Resource + "picture.png";\r
-        private static bool _flagGetViewStyle = false;\r
-        private static bool _flagOnThemeChangedEvent = false;\r
-\r
-        [SetUp]\r
-        public void Init()\r
-        {\r
-            Tizen.Log.Info(TAG, "Init() is called!");\r
-        }\r
-\r
-        [TearDown]\r
-        public void Destroy()\r
-        {\r
-            Tizen.Log.Info(TAG, "Destroy() is called!");\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test Switch empty constructor. Check it has been triggered")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Switch.Switch C")]\r
-        [Property("SPEC_URL", "-")]\r
-        [Property("CRITERIA", "CONSTR")]\r
-        [Property("COVPARAM", "")]\r
-        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]\r
-        public void Switch_CHECK_VALUE()\r
-        {\r
-            /* TEST CODE */\r
-            var _switch = new Switch();\r
-            Assert.IsNotNull(_switch, "Should be not null!");\r
-            Assert.IsInstanceOf<Switch>(_switch, "Should be an instance of Switch!");\r
-\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test Switch constructor using string. Check whether Switch is successfully created or not.")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Switch.Switch C")]\r
-        [Property("SPEC_URL", "-")]\r
-        [Property("CRITERIA", "CONSTR")]\r
-        [Property("COVPARAM", "string")]\r
-        [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]\r
-        public void Switch_INIT_WITH_STRING()\r
-        {\r
-            /* TEST CODE */\r
-            StyleManager.Instance.Theme = "default";\r
-            StyleManager.Instance.RegisterStyle("defaultSwitch", "default", typeof(DefaultSwitchStyle));\r
-            var switch1 = new Switch("defaultSwitch");\r
-            Assert.IsNotNull(switch1, "Should be not null!");\r
-            Assert.IsInstanceOf<Switch>(switch1, "Should be an instance of Switch!");\r
-        }\r
-\r
-        [Test]\r
-        [Category("P2")]\r
-        [Description("Check exception when constructing a Switch with nonexistent style.")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Switch.Switch C")]\r
-        [Property("SPEC_URL", "-")]\r
-        [Property("CRITERIA", "CONSTX")]\r
-        [Property("COVPARAM", "string")]\r
-        [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]\r
-        public void Switch_INIT_WITH_STRING_Exception()\r
-        {\r
-            /* TEST CODE */\r
-            try\r
-            {\r
-                var switch1 = new Switch("defaultSwitchX");\r
-                Assert.Fail("Should throw the Exception: There is no style of defaultSwitchX !");\r
-            }\r
-            catch(InvalidOperationException e)\r
-            {\r
-                if (e != null)\r
-                {\r
-                    Assert.Pass("InvalidOperationException: passed!");\r
-                }\r
-            }\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test Switch constructor using style. Check whether Switch is successfully created or not.")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Switch.Switch C")]\r
-        [Property("SPEC_URL", "-")]\r
-        [Property("CRITERIA", "CONSTR")]\r
-        [Property("COVPARAM", "SwitchStyle")]\r
-        [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]\r
-        public void Switch_INIT_WITH_STYLE()\r
-        {\r
-            /* TEST CODE */\r
-            var style = new SwitchStyle();\r
-            Assert.IsNotNull(style, "Should be not null!");\r
-            Assert.IsInstanceOf<SwitchStyle>(style, "Should be an instance of SwitchStyle!");\r
-\r
-            var _switch = new Switch(style);\r
-            Assert.IsNotNull(_switch, "Should be not null!");\r
-            Assert.IsInstanceOf<Switch>(_switch, "Should be an instance of Switch!");\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test Style. Check whether Style is readable.")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Switch.Style A")]\r
-        [Property("SPEC_URL", "-")]\r
-        [Property("CRITERIA", "PRO")]\r
-        [Property("AUTHOR", "Xianbing teng, xb.teng@samsung.com")]\r
-        public void Style_CHECK_GET_VALUE()\r
-        {\r
-            /* TEST CODE */\r
-            var _switch = new Switch();\r
-            Assert.IsNotNull(_switch, "Should be not null");\r
-            Assert.IsInstanceOf<Switch>(_switch, "Should be an instance of Switch!");\r
-\r
-            var style = _switch.Style;\r
-            Assert.IsNotNull(style, "Should be not null");\r
-            Assert.IsInstanceOf<SwitchStyle>(style, "Should be an instance of SwitchStyle!");\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test SwitchBackgroundImageURLSelector. Check whether SwitchBackgroundImageURLSelector is readable and writable.")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Switch.SwitchBackgroundImageURLSelector A")]\r
-        [Property("SPEC_URL", "-")]\r
-        [Property("CRITERIA", "PRW")]\r
-        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]\r
-        public void SwitchBackgroundImageURLSelector_SET_GET_VALUE()\r
-        {\r
-            /* TEST CODE */\r
-            var _switch = new Switch();\r
-            Assert.IsNotNull(_switch, "Should be not null!");\r
-            Assert.IsInstanceOf<Switch>(_switch, "Should be equal!");\r
-\r
-            StringSelector stringSelector = new StringSelector\r
-            {\r
-                Normal = _image_path,\r
-                Selected = _image_path,\r
-            };\r
-            Assert.IsNotNull(stringSelector, "Should be not null!");\r
-            Assert.IsInstanceOf<StringSelector>(stringSelector, "Should be equal!");\r
-\r
-            _switch.SwitchBackgroundImageURLSelector = stringSelector;\r
-            Assert.AreEqual(stringSelector.Normal, _switch.SwitchBackgroundImageURLSelector.Normal, "Should be equals to the set value of SwitchBackgroundImageURLSelector Normal");\r
-            Assert.AreEqual(stringSelector.Selected, _switch.SwitchBackgroundImageURLSelector.Selected, "Should be equals to the set value of SwitchBackgroundImageURLSelector Selected");\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test SwitchHandlerImageURL. Check whether SwitchHandlerImageURL is readable and writable.")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Switch.SwitchHandlerImageURL A")]\r
-        [Property("SPEC_URL", "-")]\r
-        [Property("CRITERIA", "PRW")]\r
-        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]\r
-        public void SwitchHandlerImageURL_SET_GET_VALUE()\r
-        {\r
-            /* TEST CODE */\r
-            var _switch = new Switch();\r
-            Assert.IsNotNull(_switch, "Should be not null!");\r
-            Assert.IsInstanceOf<Switch>(_switch, "Should be equal!");\r
-\r
-            _switch.SwitchHandlerImageURL = _image_path;\r
-            Assert.AreEqual(_image_path, _switch.SwitchHandlerImageURL, "Should be equals to the set value of SwitchHandlerImageURL");\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test SwitchHandlerImageURLSelector. Check whether SwitchHandlerImageURLSelector is readable and writable.")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Switch.SwitchHandlerImageURLSelector A")]\r
-        [Property("SPEC_URL", "-")]\r
-        [Property("CRITERIA", "PRW")]\r
-        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]\r
-        public void SwitchHandlerImageURLSelector_SET_GET_VALUE()\r
-        {\r
-            /* TEST CODE */\r
-            var _switch = new Switch();\r
-            Assert.IsNotNull(_switch, "Should be not null!");\r
-            Assert.IsInstanceOf<Switch>(_switch, "Should be equal!");\r
-\r
-            StringSelector stringSelector = new StringSelector\r
-            {\r
-                Normal = _image_path,\r
-                Selected = _image_path,\r
-            };\r
-            Assert.IsNotNull(stringSelector, "Should be not null!");\r
-            Assert.IsInstanceOf<StringSelector>(stringSelector, "Should be equal!");\r
-\r
-            _switch.SwitchHandlerImageURLSelector = stringSelector;\r
-            Assert.AreEqual(stringSelector.Normal, _switch.SwitchHandlerImageURLSelector.Normal, "Should be equals to the set value of SwitchHandlerImageURLSelector Normal");\r
-            Assert.AreEqual(stringSelector.Selected, _switch.SwitchHandlerImageURLSelector.Selected, "Should be equals to the set value of SwitchHandlerImageURLSelector Selected");\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test SwitchHandlerImageSize. Check whether SwitchHandlerImageSize is readable and writable.")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Switch.SwitchHandlerImageSize A")]\r
-        [Property("SPEC_URL", "-")]\r
-        [Property("CRITERIA", "PRW")]\r
-        [Property("AUTHOR", "Ma Junqing, junqing.ma@samsung.com")]\r
-        public void SwitchHandlerImageSize_SET_GET_VALUE()\r
-        {\r
-            /* TEST CODE */\r
-            var _switch = new Switch();\r
-            Assert.IsNotNull(_switch, "Should be not null!");\r
-            Assert.IsInstanceOf<Switch>(_switch, "Should be equal!");\r
-\r
-            _switch.SwitchHandlerImageSize = new Size(10, 10);\r
-            Assert.AreEqual(10, _switch.SwitchHandlerImageSize.Width, "Should be equals to the set value of SwitchHandlerImageSize2D.Width");\r
-            Assert.AreEqual(10, _switch.SwitchHandlerImageSize.Height, "Should be equals to the set value of SwitchHandlerImageSize2D.Height");\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test Dispose, try to dispose the Switch.")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Switch.Dispose M")]\r
-        [Property("SPEC_URL", "-")]\r
-        [Property("CRITERIA", "MCST")]\r
-        [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]\r
-        public void Dispose_TEST()\r
-        {\r
-            /* TEST CODE */\r
-            try\r
-            {\r
-                var mySwitch = new Switch();\r
-                Assert.IsNotNull(mySwitch, "Should be not null!");\r
-                Assert.IsInstanceOf<Switch>(mySwitch, "Should be equal!");\r
-\r
-                mySwitch.Dispose();\r
-            }\r
-            catch (Exception e)\r
-            {\r
-                Tizen.Log.Error(TAG, "Caught Exception" + e.ToString());\r
-                LogUtils.Write(LogUtils.DEBUG, LogUtils.TAG, "Caught Exception" + e.ToString());\r
-                Assert.Fail("Caught Exception" + e.ToString());\r
-            }\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test GetViewStyle. Check whether GetViewStyle works or not.")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Switch.GetViewStyle M")]\r
-        [Property("SPEC_URL", " - ")]\r
-        [Property("CRITERIA", "MR")]\r
-        [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]\r
-        public void GetViewStyle_CHECK_RETURN_VALUE()\r
-        {\r
-            try\r
-            {\r
-                _flagGetViewStyle = false;\r
-                var _switch = new MySwitch();\r
-                var style = _switch.Style;\r
-                Assert.IsNotNull(style, "Should be not null");\r
-                Assert.IsTrue(_flagGetViewStyle, "Should be true!");\r
-            }\r
-            catch (Exception e)\r
-            {\r
-                Assert.Fail("Caught Exception" + e.ToString());\r
-            }\r
-        }\r
-\r
-        [Test]\r
-        [Category("P1")]\r
-        [Description("Test OnThemeChangedEvent. Check whether OnThemeChangedEvent works or not.")]\r
-        [Property("SPEC", "Tizen.NUI.Components.Switch.OnThemeChangedEvent M")]\r
-        [Property("SPEC_URL", " - ")]\r
-        [Property("CRITERIA", "MR")]\r
-        [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]\r
-        public void OnThemeChangedEvent_CHECK_RETURN_VALUE()\r
-        {\r
-            try\r
-            {\r
-                _flagOnThemeChangedEvent = false;\r
-                StyleManager.Instance.Theme = "Family";\r
-                var _switch = new Switch();\r
-                StyleManager.Instance.Theme = "Food";\r
-                Assert.IsNotNull(_switch, "Should be not null");\r
-                Assert.IsTrue(_flagOnThemeChangedEvent, "Should be true!");\r
-            }\r
-            catch (Exception e)\r
-            {\r
-                Assert.Fail("Caught Exception" + e.ToString());\r
-            }\r
-        }\r
-\r
-        public class MySwitch : Switch\r
-        {\r
-            public MySwitch () : base() {}\r
-\r
-            protected override ViewStyle GetViewStyle()\r
-            {\r
-                _flagGetViewStyle = true;\r
-                return base.GetViewStyle();\r
-            }\r
-\r
-            protected override void OnThemeChangedEvent(object sender, StyleManager.ThemeChangeEventArgs e)\r
-            {\r
-                _flagOnThemeChangedEvent = true;\r
-            }\r
-        }\r
-\r
-        public class DefaultSwitchStyle : StyleBase\r
-        {\r
-            protected override ViewStyle GetViewStyle()\r
-            {\r
-                return new SwitchStyle();\r
-            }\r
-        }\r
-    }\r
-}\r
+            public ViewStyle CreateMyViewStyle()
+            {
+                return base.CreateViewStyle();
+            }
+
+            protected override void OnThemeChangedEvent(object sender, StyleManager.ThemeChangeEventArgs e)
+            {
+                _flagOnThemeChangedEvent = true;
+            }
+        }
+
+        public class DefaultSwitchStyle : StyleBase
+        {
+            protected override ViewStyle GetViewStyle()
+            {
+                return new SwitchStyle();
+            }
+        }
+    }
+}
old mode 100755 (executable)
new mode 100644 (file)
index abca16b..23be3ac
@@ -13,7 +13,6 @@ namespace Tizen.NUI.Components.Tests
     {
         private const string TAG = "Components";
         private bool _checkValue;
-        private static bool _flagGetViewStyle = true;
         private static bool _flagOnThemeChangedEvent = true;
 
         [SetUp]
@@ -84,10 +83,7 @@ namespace Tizen.NUI.Components.Tests
             }
             catch(InvalidOperationException e)
             {
-                if (e != null)\r
-                {
-                    Assert.Pass("InvalidOperationException: passed!");
-                }
+                Assert.Pass("InvalidOperationException: passed!");
             }
         }
 
@@ -168,11 +164,8 @@ namespace Tizen.NUI.Components.Tests
                 Assert.Fail("Should throw the ArgumentException !");
             }
             catch(ArgumentException e)
-            {\r
-                if (e != null)\r
-                {
-                    Assert.Pass("ArgumentException: passed!");
-                }
+            {
+                Assert.Pass("ArgumentException: passed!");
             }
         }
 
@@ -384,11 +377,8 @@ namespace Tizen.NUI.Components.Tests
                 Assert.Fail("Should throw the NullReferenceException!");
             }
             catch(NullReferenceException e)
-            {\r
-                if (e != null)\r
-                {
-                    Assert.Pass("NullReferenceException: passed!");
-                }
+            {
+                Assert.Pass("NullReferenceException: passed!");
             }
         }
 
@@ -469,11 +459,8 @@ namespace Tizen.NUI.Components.Tests
                 Assert.Fail("Should throw the ArgumentException!");
             }
             catch (ArgumentException e)
-            {\r
-                if (e != null)
-                {
-                    Assert.Pass("ArgumentException: passed!");
-                }\r
+            {
+                Assert.Pass("ArgumentException: passed!");
             }
         }
 
@@ -605,24 +592,22 @@ namespace Tizen.NUI.Components.Tests
             {
                 Assert.Fail("Caught Exception" + e.ToString());
             }
-        }
-
+        }\r
+\r
         [Test]
         [Category("P1")]
-        [Description("Test GetViewStyle. Check whether GetViewStyle works or not.")]
-        [Property("SPEC", "Tizen.NUI.Components.Tab.GetViewStyle M")]
+        [Description("Test GetViewStyle. Check whether CreateViewStyle works or not.")]
+        [Property("SPEC", "Tizen.NUI.Components.Tab.CreateViewStyle M")]
         [Property("SPEC_URL", " - ")]
         [Property("CRITERIA", "MR")]
         [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]
-        public void GetViewStyle_CHECK_RETURN_VALUE()
+        public void CreateViewStyle_CHECK_RETURN_VALUE()
         {
             try
             {
-                _flagGetViewStyle = false;
                 var tab = new MyTab();
-                var style = tab.Style;
+                ViewStyle style = tab.CreateMyViewStyle();
                 Assert.IsNotNull(style, "Should be not null");
-                Assert.IsTrue(_flagGetViewStyle, "Should be true!");
             }
             catch (Exception e)
             {
@@ -663,13 +648,12 @@ namespace Tizen.NUI.Components.Tests
             { }
 
             public MyTab(string style) : base(style)
-            { }
-
-            protected override ViewStyle GetViewStyle()
-            {
-                _flagGetViewStyle = true;
-                return new TabStyle();
-            }
+            { }\r
+\r
+            public ViewStyle CreateMyViewStyle()\r
+            {\r
+                return base.CreateViewStyle();\r
+            }\r
 
             protected override void OnUpdate()
             {
old mode 100755 (executable)
new mode 100644 (file)
index 39d871d..5240de9
@@ -12,7 +12,6 @@ namespace Tizen.NUI.Components.Tests
     public class ToastTests
     {
         private const string TAG = "Components";
-        private static bool _flagGetViewStyle = false;
 
         [SetUp]
         public void Init()
@@ -77,10 +76,7 @@ namespace Tizen.NUI.Components.Tests
             }
             catch(InvalidOperationException e)
             {
-                if(e != null)\r
-                {
-                    Assert.Pass("InvalidOperationException: passed!");
-                }
+                Assert.Pass("InvalidOperationException: passed!");
             }
         }
 
@@ -340,24 +336,22 @@ namespace Tizen.NUI.Components.Tests
             {
                 Assert.Fail("Caught Exception" + e.ToString());
             }
-        }
-
+        }\r
+\r
         [Test]
         [Category("P1")]
-        [Description("Test GetViewStyle. Check whether GetViewStyle works or not.")]
-        [Property("SPEC", "Tizen.NUI.Components.Toast.GetViewStyle M")]
+        [Description("Test GetViewStyle. Check whether CreateViewStyle works or not.")]
+        [Property("SPEC", "Tizen.NUI.Components.Toast.CreateViewStyle M")]
         [Property("SPEC_URL", " - ")]
         [Property("CRITERIA", "MR")]
         [Property("AUTHOR", "Xianbing Teng, xb.teng@samsung.com")]
-        public void GetViewStyle_CHECK_RETURN_VALUE()
+        public void CreateViewStyle_CHECK_RETURN_VALUE()
         {
             try
             {
-                _flagGetViewStyle = false;
                 var button = new MyToast();
-                var style = button.Style;
+                ViewStyle style = button.CreateMyViewStyle();
                 Assert.IsNotNull(style, "Should be not null");
-                Assert.IsTrue(_flagGetViewStyle, "Should be true!");
             }
             catch (Exception e)
             {
@@ -367,12 +361,11 @@ namespace Tizen.NUI.Components.Tests
 
         public class MyToast : Toast
         {
-            public MyToast () : base() {}
+            public MyToast() : base() { }
 
-            protected override ViewStyle GetViewStyle()
+            public ViewStyle CreateMyViewStyle()
             {
-                _flagGetViewStyle = true;
-                return base.GetViewStyle();
+                return base.CreateViewStyle();
             }
         }