3 using NUnit.Framework.TUnit;
5 using Tizen.NUI.Components;
6 using Tizen.NUI.BaseComponents;
8 namespace Tizen.NUI.Components.Devel.Tests
10 using tlog = Tizen.Log;
13 [Description("Controls/DatePicker")]
14 public class DatePickerTest
16 private const string tag = "NUITEST";
18 internal class MyDatePicker : DatePicker
20 public MyDatePicker() : base()
23 public void OnDispose(DisposeTypes types)
28 public override void OnInitialize()
33 public override void ApplyStyle(ViewStyle viewStyle)
35 base.ApplyStyle(viewStyle);
39 internal class MyDatePickerStyle : DatePickerStyle
46 tlog.Info(tag, "Init() is called!");
52 tlog.Info(tag, "Destroy() is called!");
57 //[Description("DatePicker constructor.")]
58 //[Property("SPEC", "Tizen.NUI.Components.DatePicker.constructor C")]
59 //[Property("SPEC_URL", "-")]
60 //[Property("CRITERIA", "CONSTR")]
61 //[Property("COVPARAM", "")]
62 //[Property("AUTHOR", "guowei.wang@samsung.com")]
63 //public void DatePickerConstructor()
65 // tlog.Debug(tag, $"DatePickerConstructor START");
67 // var testingTarget = new MyDatePicker();
68 // Assert.IsNotNull(testingTarget, "null handle");
69 // Assert.IsInstanceOf<DatePicker>(testingTarget, "Should return DatePicker instance.");
73 // testingTarget.OnDispose(DisposeTypes.Explicit);
75 // catch (Exception e)
77 // tlog.Debug(tag, e.Message.ToString());
78 // Assert.Fail("Caught Exception : Failed!");
81 // testingTarget.Dispose();
82 // tlog.Debug(tag, $"DatePickerConstructor END (OK)");
87 //[Description("DatePicker OnInitialize.")]
88 //[Property("SPEC", "Tizen.NUI.Components.DatePicker.OnInitialize M")]
89 //[Property("SPEC_URL", "-")]
90 //[Property("CRITERIA", "MR")]
91 //[Property("COVPARAM", "")]
92 //[Property("AUTHOR", "guowei.wang@samsung.com")]
93 //public void DatePickerOnInitialize()
95 // tlog.Debug(tag, $"DatePickerOnInitialize START");
97 // var testingTarget = new MyDatePicker();
98 // Assert.IsNotNull(testingTarget, "null handle");
99 // Assert.IsInstanceOf<DatePicker>(testingTarget, "Should return DatePicker instance.");
103 // testingTarget.OnInitialize();
105 // catch (Exception e)
107 // tlog.Debug(tag, e.Message.ToString());
108 // Assert.Fail("Caught Exception : Failed!");
111 // testingTarget.Dispose();
112 // tlog.Debug(tag, $"DatePickerOnInitialize END (OK)");
117 //[Description("DatePicker ApplyStyle.")]
118 //[Property("SPEC", "Tizen.NUI.Components.DatePicker.ApplyStyle M")]
119 //[Property("SPEC_URL", "-")]
120 //[Property("CRITERIA", "MR")]
121 //[Property("COVPARAM", "")]
122 //[Property("AUTHOR", "guowei.wang@samsung.com")]
123 //public void DatePickerApplyStyle()
125 // tlog.Debug(tag, $"DatePickerApplyStyle START");
127 // var testingTarget = new MyDatePicker();
128 // Assert.IsNotNull(testingTarget, "null handle");
129 // Assert.IsInstanceOf<DatePicker>(testingTarget, "Should return DatePicker instance.");
133 // ViewStyle style = new ViewStyle()
135 // Size = new Size(30, 200)
137 // testingTarget.ApplyStyle(style);
139 // catch (Exception e)
141 // tlog.Debug(tag, e.Message.ToString());
142 // Assert.Fail("Caught Exception : Failed!");
145 // testingTarget.Dispose();
146 // tlog.Debug(tag, $"DatePickerApplyStyle END (OK)");