b381b822054cac56ae52ff4dd1dbe1b9b3698cca
[platform/core/csapi/tizenfx.git] / test / Tizen.NUI.Tests / Tizen.NUI.Components.Devel.Tests / testcase / Controls / TSSlider.cs
1 using global::System;
2 using NUnit.Framework;
3 using NUnit.Framework.TUnit;
4 using Tizen.NUI;
5 using Tizen.NUI.Components;
6 using Tizen.NUI.BaseComponents;
7
8 namespace Tizen.NUI.Components.Devel.Tests
9 {
10     using tlog = Tizen.Log;
11
12     [TestFixture]
13     [Description("Controls/Slider")]
14     public class SliderTest
15     {
16         private const string tag = "NUITEST";
17         private string image_path = Tizen.Applications.Application.Current.DirectoryInfo.Resource + "picture.png";
18
19         [Obsolete]
20         private EventHandler<Slider.ValueChangedArgs> OnValueChangedEvent()
21         {
22             return null;
23         }
24
25         [Obsolete]
26         private EventHandler<Slider.SlidingFinishedArgs> OnSlidingFinishedEvent()
27         {
28             return null;
29         }
30
31         private EventHandler<SliderValueChangedEventArgs> OnValueChanged()
32         {
33             return null;
34         }
35
36         private EventHandler<SliderSlidingStartedEventArgs> OnSlidingStarted()
37         {
38             return null;
39         }
40
41         private EventHandler<SliderSlidingFinishedEventArgs> OnSlidingFinished()
42         {
43             return null;
44         }
45
46         [Obsolete]
47         private EventHandler<Slider.StateChangedArgs> OnStateChangedEvent()
48         {
49             return null;
50         }
51
52         internal class MySlider : Slider
53         {
54             public MySlider() : base()
55             { }
56
57             public bool OnAccessibilityShouldReportZeroChildren()
58             {
59                 return base.AccessibilityShouldReportZeroChildren();
60             }
61
62             public double OnAccessibilityGetMinimum()
63             {
64                 return base.AccessibilityGetMinimum();
65             }
66
67             public double OnAccessibilityGetCurrent()
68             {
69                 return base.AccessibilityGetCurrent();
70             }
71
72             public double OnAccessibilityGetMaximum()
73             {
74                 return base.AccessibilityGetMaximum();
75             }
76
77             public bool OnAccessibilitySetCurrent(double value)
78             {
79                 return base.AccessibilitySetCurrent(value);
80             }
81
82             public double OnAccessibilityGetMinimumIncrement()
83             {
84                 return base.AccessibilityGetMinimumIncrement();
85             }
86
87             public void MyOnUpdate()
88             {
89                 base.OnUpdate();
90             }
91         }
92
93         [SetUp]
94         public void Init()
95         {
96             tlog.Info(tag, "Init() is called!");
97         }
98
99         [TearDown]
100         public void Destroy()
101         {
102             tlog.Info(tag, "Destroy() is called!");
103         }
104
105         [Test]
106         [Category("P1")]
107         [Description("Slider TrackThickness.")]
108         [Property("SPEC", "Tizen.NUI.Components.Slider.TrackThickness A")]
109         [Property("SPEC_URL", "-")]
110         [Property("CRITERIA", "PRW")]
111         [Property("COVPARAM", "")]
112         [Property("AUTHOR", "guowei.wang@samsung.com")]
113         public void SliderTrackThickness()
114         {
115             tlog.Debug(tag, $"SliderTrackThickness START");
116
117             var testingTarget = new Slider()
118             {
119                 Direction = Slider.DirectionType.Vertical,
120             };
121             Assert.IsNotNull(testingTarget, "null handle");
122             Assert.IsInstanceOf<Slider>(testingTarget, "Should return Slider instance.");
123
124             testingTarget.IsEnabled = true;
125             tlog.Debug(tag, "IsEnabled : " + testingTarget.IsEnabled);
126
127             testingTarget.TrackThickness = 30;
128             tlog.Debug(tag, "TrackThickness : " + testingTarget.TrackThickness);
129
130             testingTarget.Dispose();
131             tlog.Debug(tag, $"TrackThickness END (OK)");
132         }
133
134         [Test]
135         [Category("P1")]
136         [Description("Slider WarningStartValue.")]
137         [Property("SPEC", "Tizen.NUI.Components.Slider.WarningStartValue A")]
138         [Property("SPEC_URL", "-")]
139         [Property("CRITERIA", "PRW")]
140         [Property("COVPARAM", "")]
141         [Property("AUTHOR", "guowei.wang@samsung.com")]
142         public void SliderWarningStartValue()
143         {
144             tlog.Debug(tag, $"SliderWarningStartValue START");
145
146             var testingTarget = new Slider()
147             {
148                 Direction = Slider.DirectionType.Vertical,
149             };
150             Assert.IsNotNull(testingTarget, "null handle");
151             Assert.IsInstanceOf<Slider>(testingTarget, "Should return Slider instance.");
152
153             testingTarget.IsEnabled = true;
154             tlog.Debug(tag, "IsEnabled : " + testingTarget.IsEnabled);
155
156             testingTarget.WarningStartValue = 30.0f;
157             tlog.Debug(tag, "WarningStartValue : " + testingTarget.WarningStartValue);
158
159             testingTarget.WarningTrackColor = Color.Cyan;
160             tlog.Debug(tag, "WarningTrackColor :" + testingTarget.WarningTrackColor);
161
162             testingTarget.WarningSlidedTrackColor = Color.Green;
163             tlog.Debug(tag, "WarningSlidedTrackColor :" + testingTarget.WarningSlidedTrackColor);
164
165             testingTarget.WarningThumbColor = Color.Red;
166             tlog.Debug(tag, "WarningThumbColor : " + testingTarget.WarningThumbColor);
167
168             Selector<string> url = new Selector<string>()
169             { 
170                 All = image_path,
171             };
172             testingTarget.WarningThumbImageUrl = url;
173             tlog.Debug(tag, "WarningThumbImageUrl : " + testingTarget.WarningThumbImageUrl);
174
175             try
176             {
177                 testingTarget.WarningThumbImageUrl = null;
178             }
179             catch (NullReferenceException)
180             {
181                 testingTarget.Dispose();
182                 tlog.Debug(tag, $"SliderThumbImageUrl END (OK)");
183                 Assert.Pass("Caught NullReferenceException : Passed!");
184             }
185         }
186
187         [Test]
188         [Category("P1")]
189         [Description("Slider OnFocusGained.")]
190         [Property("SPEC", "Tizen.NUI.Components.Slider.OnFocusGained M")]
191         [Property("SPEC_URL", "-")]
192         [Property("CRITERIA", "MR")]
193         [Property("COVPARAM", "")]
194         [Property("AUTHOR", "guowei.wang@samsung.com")]
195         public void SliderOnFocusGained()
196         {
197             tlog.Debug(tag, $"SliderOnFocusGained START");
198
199             var testingTarget = new Slider()
200             {
201                 Direction = Slider.DirectionType.Vertical,
202             };
203             Assert.IsNotNull(testingTarget, "null handle");
204             Assert.IsInstanceOf<Slider>(testingTarget, "Should return Slider instance.");
205
206             try
207             {
208                 testingTarget.OnFocusGained();
209                 testingTarget.OnFocusLost();
210             }
211             catch (Exception e)
212             {
213                 tlog.Debug(tag, e.Message.ToString());
214                 Assert.Fail("Caught Exception : Failed!");
215             }
216
217             testingTarget.Dispose();
218             tlog.Debug(tag, $"SliderOnFocusGained END (OK)");
219         }
220
221         [Test]
222         [Category("P1")]
223         [Description("Slider OnKey.")]
224         [Property("SPEC", "Tizen.NUI.Components.Slider.OnKey M")]
225         [Property("SPEC_URL", "-")]
226         [Property("CRITERIA", "MR")]
227         [Property("COVPARAM", "")]
228         [Property("AUTHOR", "guowei.wang@samsung.com")]
229         public void SliderOnKey()
230         {
231             tlog.Debug(tag, $"SliderOnKey START");
232
233             var testingTarget = new Slider()
234             {
235                 Direction = Slider.DirectionType.Vertical,
236                 IsEnabled = true,
237                 IsDiscrete = true,
238             };
239             Assert.IsNotNull(testingTarget, "null handle");
240             Assert.IsInstanceOf<Slider>(testingTarget, "Should return Slider instance.");
241
242             testingTarget.MinValue = 0.0f;
243             testingTarget.MaxValue = 100.0f;
244             testingTarget.CurrentValue = 30.0f;
245
246             Key dummy = null;
247             var result = testingTarget.OnKey(dummy);
248             Assert.AreEqual(false, result, "should be equal here!");
249
250             using (Key key = new Key())
251             {
252                 key.State = Key.StateType.Down;
253                 key.KeyPressedName = "Down";
254
255                 try
256                 {
257                     testingTarget.OnKey(key);
258                 }
259                 catch (Exception e)
260                 {
261                     tlog.Debug(tag, e.Message.ToString());
262                     Assert.Fail("Caught Exception : Failed!");
263                 }
264
265                 key.State = Key.StateType.Up;
266                 try
267                 {
268                     testingTarget.OnKey(key);
269                 }
270                 catch (Exception e)
271                 {
272                     tlog.Debug(tag, e.Message.ToString());
273                     Assert.Fail("Caught Exception : Failed!");
274                 }
275             }
276
277             testingTarget.Dispose();
278             tlog.Debug(tag, $"SliderOnKey END (OK)");
279         }
280
281         [Test]
282         [Category("P1")]
283         [Description("Slider OnKey.")]
284         [Property("SPEC", "Tizen.NUI.Components.Slider.OnKey M")]
285         [Property("SPEC_URL", "-")]
286         [Property("CRITERIA", "MR")]
287         [Property("COVPARAM", "")]
288         [Property("AUTHOR", "guowei.wang@samsung.com")]
289         public void SliderOnKeyKeyPressedNameUp()
290         {
291             tlog.Debug(tag, $"SliderOnKeyKeyPressedNameUp START");
292
293             var testingTarget = new Slider()
294             {
295                 Direction = Slider.DirectionType.Vertical,
296                 IsEnabled = true,
297             };
298             Assert.IsNotNull(testingTarget, "null handle");
299             Assert.IsInstanceOf<Slider>(testingTarget, "Should return Slider instance.");
300
301             testingTarget.MinValue = 0.0f;
302             testingTarget.MaxValue = 100.0f;
303             testingTarget.CurrentValue = 30.0f;
304
305             using (Key key = new Key())
306             {
307                 key.State = Key.StateType.Down;
308                 key.KeyPressedName = "Up";
309
310                 try
311                 {
312                     testingTarget.OnKey(key);
313                 }
314                 catch (Exception e)
315                 {
316                     tlog.Debug(tag, e.Message.ToString());
317                     Assert.Fail("Caught Exception : Failed!");
318                 }
319             }
320
321             testingTarget.Dispose();
322             tlog.Debug(tag, $"SliderOnKeyKeyPressedNameUp END (OK)");
323         }
324
325         [Test]
326         [Category("P1")]
327         [Description("Slider ValueChangedEvent.")]
328         [Property("SPEC", "Tizen.NUI.Components.Slider.ValueChangedEvent A")]
329         [Property("SPEC_URL", "-")]
330         [Property("CRITERIA", "PRW")]
331         [Property("COVPARAM", "")]
332         [Property("AUTHOR", "guowei.wang@samsung.com")]
333         [Obsolete]
334         public void SliderValueChangedEvent()
335         {
336             tlog.Debug(tag, $"SliderValueChangedEvent START");
337
338             var testingTarget = new Slider()
339             {
340                 Direction = Slider.DirectionType.Vertical,
341                 IsEnabled = true,
342             };
343             Assert.IsNotNull(testingTarget, "null handle");
344             Assert.IsInstanceOf<Slider>(testingTarget, "Should return Slider instance.");
345
346             testingTarget.ValueChangedEvent += OnValueChangedEvent();
347             testingTarget.ValueChangedEvent -= OnValueChangedEvent();
348
349             testingTarget.Dispose();
350             tlog.Debug(tag, $"SliderValueChangedEvent END (OK)");
351         }
352
353         [Test]
354         [Category("P1")]
355         [Description("Slider SlidingFinishedEvent.")]
356         [Property("SPEC", "Tizen.NUI.Components.Slider.SlidingFinishedEvent A")]
357         [Property("SPEC_URL", "-")]
358         [Property("CRITERIA", "PRW")]
359         [Property("COVPARAM", "")]
360         [Property("AUTHOR", "guowei.wang@samsung.com")]
361         [Obsolete]
362         public void SliderSlidingFinishedEvent()
363         {
364             tlog.Debug(tag, $"SliderSlidingFinishedEvent START");
365
366             var testingTarget = new Slider()
367             {
368                 Direction = Slider.DirectionType.Vertical,
369                 IsEnabled = true,
370             };
371             Assert.IsNotNull(testingTarget, "null handle");
372             Assert.IsInstanceOf<Slider>(testingTarget, "Should return Slider instance.");
373
374             testingTarget.SlidingFinishedEvent += OnSlidingFinishedEvent();
375             testingTarget.SlidingFinishedEvent -= OnSlidingFinishedEvent();
376
377             testingTarget.Dispose();
378             tlog.Debug(tag, $"SliderValueChangedEvent END (OK)");
379         }
380
381         [Test]
382         [Category("P1")]
383         [Description("SliderSlidingStartedEventArgs CurrentValue.")]
384         [Property("SPEC", "Tizen.NUI.Components.Slider.OnKey A")]
385         [Property("SPEC_URL", "-")]
386         [Property("CRITERIA", "PRW")]
387         [Property("COVPARAM", "")]
388         [Property("AUTHOR", "guowei.wang@samsung.com")]
389         public void SliderSlidingStartedEventArgsCurrentValue()
390         {
391             tlog.Debug(tag, $"SliderSlidingStartedEventArgsCurrentValue START");
392
393             var testingTarget = new SliderSlidingStartedEventArgs();
394             Assert.IsNotNull(testingTarget, "null handle");
395             Assert.IsInstanceOf<SliderSlidingStartedEventArgs>(testingTarget, "Should return SliderSlidingStartedEventArgs instance.");
396
397             testingTarget.CurrentValue = 30.0f;
398             tlog.Debug(tag, "CurrentValue : " + testingTarget.CurrentValue);
399
400             tlog.Debug(tag, $"SliderSlidingStartedEventArgsCurrentValue END (OK)");
401         }
402
403         [Test]
404         [Category("P1")]
405         [Description("Slider ValueChanged.")]
406         [Property("SPEC", "Tizen.NUI.Components.Slider.ValueChanged A")]
407         [Property("SPEC_URL", "-")]
408         [Property("CRITERIA", "PRW")]
409         [Property("COVPARAM", "")]
410         [Property("AUTHOR", "guowei.wang@samsung.com")]
411         [Obsolete]
412         public void SliderValueChanged()
413         {
414             tlog.Debug(tag, $"SliderValueChanged START");
415
416             var testingTarget = new Slider()
417             {
418                 Direction = Slider.DirectionType.Vertical,
419                 IsEnabled = true,
420             };
421             Assert.IsNotNull(testingTarget, "null handle");
422             Assert.IsInstanceOf<Slider>(testingTarget, "Should return Slider instance.");
423
424             testingTarget.ValueChanged += OnValueChanged();
425             testingTarget.ValueChanged -= OnValueChanged();
426
427             testingTarget.Dispose();
428             tlog.Debug(tag, $"SliderValueChanged END (OK)");
429         }
430
431         [Test]
432         [Category("P1")]
433         [Description("Slider SlidingStarted.")]
434         [Property("SPEC", "Tizen.NUI.Components.Slider.SlidingStarted A")]
435         [Property("SPEC_URL", "-")]
436         [Property("CRITERIA", "PRW")]
437         [Property("COVPARAM", "")]
438         [Property("AUTHOR", "guowei.wang@samsung.com")]
439         [Obsolete]
440         public void SliderSlidingStarted()
441         {
442             tlog.Debug(tag, $"SliderSlidingStarted START");
443
444             var testingTarget = new Slider()
445             {
446                 Direction = Slider.DirectionType.Vertical,
447                 IsEnabled = true,
448             };
449             Assert.IsNotNull(testingTarget, "null handle");
450             Assert.IsInstanceOf<Slider>(testingTarget, "Should return Slider instance.");
451
452             testingTarget.SlidingStarted += OnSlidingStarted();
453             testingTarget.SlidingStarted -= OnSlidingStarted();
454
455             testingTarget.Dispose();
456             tlog.Debug(tag, $"SliderSlidingStarted END (OK)");
457         }
458
459         [Test]
460         [Category("P1")]
461         [Description("Slider SlidingFinished.")]
462         [Property("SPEC", "Tizen.NUI.Components.Slider.SlidingFinished A")]
463         [Property("SPEC_URL", "-")]
464         [Property("CRITERIA", "PRW")]
465         [Property("COVPARAM", "")]
466         [Property("AUTHOR", "guowei.wang@samsung.com")]
467         [Obsolete]
468         public void SliderSlidingFinished()
469         {
470             tlog.Debug(tag, $"SliderSlidingFinished START");
471
472             var testingTarget = new Slider()
473             {
474                 Direction = Slider.DirectionType.Vertical,
475                 IsEnabled = true,
476             };
477             Assert.IsNotNull(testingTarget, "null handle");
478             Assert.IsInstanceOf<Slider>(testingTarget, "Should return Slider instance.");
479
480             testingTarget.SlidingFinished += OnSlidingFinished();
481             testingTarget.SlidingFinished -= OnSlidingFinished();
482
483             testingTarget.Dispose();
484             tlog.Debug(tag, $"SliderSlidingFinished END (OK)");
485         }
486
487         [Test]
488         [Category("P1")]
489         [Description("Slider StateChangedEvent.")]
490         [Property("SPEC", "Tizen.NUI.Components.Slider.StateChangedEvent A")]
491         [Property("SPEC_URL", "-")]
492         [Property("CRITERIA", "PRW")]
493         [Property("COVPARAM", "")]
494         [Property("AUTHOR", "guowei.wang@samsung.com")]
495         [Obsolete]
496         public void SliderStateChangedEvent()
497         {
498             tlog.Debug(tag, $"SliderStateChangedEvent START");
499
500             var testingTarget = new Slider()
501             {
502                 Direction = Slider.DirectionType.Vertical,
503                 IsEnabled = true,
504             };
505             Assert.IsNotNull(testingTarget, "null handle");
506             Assert.IsInstanceOf<Slider>(testingTarget, "Should return Slider instance.");
507
508             testingTarget.StateChangedEvent += OnStateChangedEvent();
509             testingTarget.StateChangedEvent -= OnStateChangedEvent();
510
511             testingTarget.Dispose();
512             tlog.Debug(tag, $"SliderStateChangedEvent END (OK)");
513         }
514
515         [Test]
516         [Category("P1")]
517         [Description("Slider ThumbImageUrl.")]
518         [Property("SPEC", "Tizen.NUI.Components.Slider.ThumbImageUrl A")]
519         [Property("SPEC_URL", "-")]
520         [Property("CRITERIA", "PRW")]
521         [Property("COVPARAM", "")]
522         [Property("AUTHOR", "guowei.wang@samsung.com")]
523         [Obsolete]
524         public void SliderThumbImageUrl()
525         {
526             tlog.Debug(tag, $"SliderThumbImageUrl START");
527
528             var testingTarget = new Slider()
529             {
530                 Direction = Slider.DirectionType.Vertical,
531                 IsEnabled = true,
532             };
533             Assert.IsNotNull(testingTarget, "null handle");
534             Assert.IsInstanceOf<Slider>(testingTarget, "Should return Slider instance.");
535
536             tlog.Debug(tag, "ThumbImageUrl : " + testingTarget.ThumbImageUrl);
537
538             testingTarget.ThumbImageUrl = image_path;
539             tlog.Debug(tag, "ThumbImageUrl : " + testingTarget.ThumbImageUrl);
540
541             try
542             {
543                 testingTarget.ThumbImageUrl = null;
544             }
545             catch (NullReferenceException)
546             {
547                 testingTarget.Dispose();
548                 tlog.Debug(tag, $"SliderThumbImageUrl END (OK)");
549                 Assert.Pass("Caught NullReferenceException : Passed!");
550             }   
551         }
552
553         [Test]
554         [Category("P1")]
555         [Description("Slider ThumbColor.")]
556         [Property("SPEC", "Tizen.NUI.Components.Slider.ThumbColor A")]
557         [Property("SPEC_URL", "-")]
558         [Property("CRITERIA", "PRW")]
559         [Property("COVPARAM", "")]
560         [Property("AUTHOR", "guowei.wang@samsung.com")]
561         [Obsolete]
562         public void SliderThumbColor()
563         {
564             tlog.Debug(tag, $"SliderThumbColor START");
565
566             var testingTarget = new Slider()
567             {
568                 Direction = Slider.DirectionType.Vertical,
569                 IsEnabled = true,
570             };
571             Assert.IsNotNull(testingTarget, "null handle");
572             Assert.IsInstanceOf<Slider>(testingTarget, "Should return Slider instance.");
573
574             testingTarget.ThumbImageUrl = image_path;
575             testingTarget.ThumbColor = Color.Black;
576             tlog.Debug(tag, "ThumbColor : " + testingTarget.ThumbColor);
577
578             testingTarget.Dispose();
579             tlog.Debug(tag, $"SliderThumbColor END (OK)");
580         }
581
582         [Test]
583         [Category("P1")]
584         [Description("Slider AccessibilityShouldReportZeroChildren.")]
585         [Property("SPEC", "Tizen.NUI.Components.Slider.AccessibilityShouldReportZeroChildren M")]
586         [Property("SPEC_URL", "-")]
587         [Property("CRITERIA", "MR")]
588         [Property("COVPARAM", "")]
589         [Property("AUTHOR", "guowei.wang@samsung.com")]
590         [Obsolete]
591         public void SliderAccessibilityShouldReportZeroChildren()
592         {
593             tlog.Debug(tag, $"SliderAccessibilityShouldReportZeroChildren START");
594
595             var testingTarget = new MySlider()
596             {
597                 Direction = Slider.DirectionType.Vertical,
598                 IsEnabled = true,
599             };
600             Assert.IsNotNull(testingTarget, "null handle");
601             Assert.IsInstanceOf<Slider>(testingTarget, "Should return Slider instance.");
602
603             var result = testingTarget.OnAccessibilityShouldReportZeroChildren();
604             tlog.Debug(tag, "AccessibilityShouldReportZeroChildren : " + result);
605
606             testingTarget.Dispose();
607             tlog.Debug(tag, $"SliderAccessibilityShouldReportZeroChildren END (OK)");
608         }
609
610         [Test]
611         [Category("P1")]
612         [Description("Slider AccessibilityGetMinimum.")]
613         [Property("SPEC", "Tizen.NUI.Components.Slider.AccessibilityGetMinimum M")]
614         [Property("SPEC_URL", "-")]
615         [Property("CRITERIA", "MR")]
616         [Property("COVPARAM", "")]
617         [Property("AUTHOR", "guowei.wang@samsung.com")]
618         [Obsolete]
619         public void SliderAccessibilityGetMinimum()
620         {
621             tlog.Debug(tag, $"SliderAccessibilityGetMinimum START");
622
623             var testingTarget = new MySlider()
624             {
625                 Direction = Slider.DirectionType.Vertical,
626                 IsEnabled = true,
627             };
628             Assert.IsNotNull(testingTarget, "null handle");
629             Assert.IsInstanceOf<Slider>(testingTarget, "Should return Slider instance.");
630
631             testingTarget.MinValue = 0.0f;
632             testingTarget.MaxValue = 100.0f;
633             testingTarget.CurrentValue = 30.0f;
634
635             var result = testingTarget.OnAccessibilityGetMinimum();
636             tlog.Debug(tag, "AccessibilityGetMinimum : " + result);
637
638             result = testingTarget.OnAccessibilityGetMaximum();
639             tlog.Debug(tag, "AccessibilityGetMaximum : " + result);
640
641             result = testingTarget.OnAccessibilityGetCurrent();
642             tlog.Debug(tag, "AccessibilityGetCurrent : " + result);
643
644             testingTarget.Dispose();
645             tlog.Debug(tag, $"SliderAccessibilityGetMinimum END (OK)");
646         }
647
648         [Test]
649         [Category("P1")]
650         [Description("Slider AccessibilitySetCurrent.")]
651         [Property("SPEC", "Tizen.NUI.Components.Slider.AccessibilitySetCurrent M")]
652         [Property("SPEC_URL", "-")]
653         [Property("CRITERIA", "MR")]
654         [Property("COVPARAM", "")]
655         [Property("AUTHOR", "guowei.wang@samsung.com")]
656         [Obsolete]
657         public void SliderAccessibilitySetCurrent()
658         {
659             tlog.Debug(tag, $"SliderAccessibilitySetCurrent START");
660
661             var testingTarget = new MySlider()
662             {
663                 Direction = Slider.DirectionType.Vertical,
664                 IsEnabled = true,
665             };
666             Assert.IsNotNull(testingTarget, "null handle");
667             Assert.IsInstanceOf<Slider>(testingTarget, "Should return Slider instance.");
668
669             testingTarget.MinValue = 0.0f;
670             testingTarget.MaxValue = 100.0f;
671
672             var result = testingTarget.OnAccessibilitySetCurrent(30.0f);
673             tlog.Debug(tag, "AccessibilitySetCurrent : " + result);
674
675             testingTarget.Dispose();
676             tlog.Debug(tag, $"SliderAccessibilitySetCurrent END (OK)");
677         }
678
679         [Test]
680         [Category("P1")]
681         [Description("Slider AccessibilityGetMinimumIncrement.")]
682         [Property("SPEC", "Tizen.NUI.Components.Slider.AccessibilityGetMinimumIncrement M")]
683         [Property("SPEC_URL", "-")]
684         [Property("CRITERIA", "MR")]
685         [Property("COVPARAM", "")]
686         [Property("AUTHOR", "guowei.wang@samsung.com")]
687         [Obsolete]
688         public void SliderAccessibilityGetMinimumIncrement()
689         {
690             tlog.Debug(tag, $"SliderAccessibilityGetMinimumIncrement START");
691
692             var testingTarget = new MySlider()
693             {
694                 Direction = Slider.DirectionType.Vertical,
695                 IsEnabled = true,
696             };
697             Assert.IsNotNull(testingTarget, "null handle");
698             Assert.IsInstanceOf<Slider>(testingTarget, "Should return Slider instance.");
699
700             testingTarget.MinValue = 0.0f;
701             testingTarget.MaxValue = 100.0f;
702
703             var result = testingTarget.OnAccessibilityGetMinimumIncrement();
704             tlog.Debug(tag, "AccessibilityGetMinimumIncrement : " + result);
705
706             testingTarget.Dispose();
707             tlog.Debug(tag, $"SliderAccessibilityGetMinimumIncrement END (OK)");
708         }
709
710         [Test]
711         [Category("P1")]
712         [Description("Slider OnUpdate.")]
713         [Property("SPEC", "Tizen.NUI.Components.Slider.OnUpdate M")]
714         [Property("SPEC_URL", "-")]
715         [Property("CRITERIA", "MR")]
716         [Property("COVPARAM", "")]
717         [Property("AUTHOR", "guowei.wang@samsung.com")]
718         [Obsolete]
719         public void SliderOnUpdate()
720         {
721             tlog.Debug(tag, $"SliderOnUpdate START");
722
723             var testingTarget = new MySlider()
724             {
725                 Direction = Slider.DirectionType.Vertical,
726                 IsEnabled = true,
727             };
728             Assert.IsNotNull(testingTarget, "null handle");
729             Assert.IsInstanceOf<Slider>(testingTarget, "Should return Slider instance.");
730
731             testingTarget.MinValue = 0.0f;
732             testingTarget.MaxValue = 100.0f;
733             testingTarget.BgTrackColor = Color.Cyan;
734             testingTarget.LowIndicatorImageURL = image_path;
735             testingTarget.LowIndicatorSize = new Size(8, 8);
736             testingTarget.HighIndicatorImageURL = image_path;
737             testingTarget.HighIndicatorSize = new Size(10, 10);
738
739             SliderStyle style1 = new SliderStyle()
740             { 
741                 IndicatorType = Slider.IndicatorType.Image,
742             };
743             testingTarget.ApplyStyle(style1);
744
745             try
746             {
747                 testingTarget.MyOnUpdate();
748             }
749             catch (Exception e)
750             {
751                 tlog.Debug(tag, e.Message.ToString());
752                 Assert.Fail("Caught Exception : Failed!");
753             }
754
755             SliderStyle style2 = new SliderStyle()
756             {
757                 IndicatorType = Slider.IndicatorType.Text,
758             };
759             testingTarget.ApplyStyle(style2);
760
761             try
762             {
763                 testingTarget.MyOnUpdate();
764             }
765             catch (Exception e)
766             {
767                 tlog.Debug(tag, e.Message.ToString());
768                 Assert.Fail("Caught Exception : Failed!");
769             }
770
771             testingTarget.Dispose();
772             tlog.Debug(tag, $"SliderOnUpdate END (OK)");
773         }
774
775         [Test]
776         [Category("P1")]
777         [Description("Slider OnUpdate.")]
778         [Property("SPEC", "Tizen.NUI.Components.Slider.OnUpdate M")]
779         [Property("SPEC_URL", "-")]
780         [Property("CRITERIA", "MR")]
781         [Property("COVPARAM", "")]
782         [Property("AUTHOR", "guowei.wang@samsung.com")]
783         [Obsolete]
784         public void SliderOnUpdateDirectionIsHorizontal()
785         {
786             tlog.Debug(tag, $"SliderOnUpdateDirectionIsHorizontal START");
787
788             var testingTarget = new MySlider()
789             {
790                 Size = new Size(100, 5),
791                 Direction = Slider.DirectionType.Horizontal,
792                 IsEnabled = true,
793             };
794             Assert.IsNotNull(testingTarget, "null handle");
795             Assert.IsInstanceOf<Slider>(testingTarget, "Should return Slider instance.");
796
797             testingTarget.MinValue = 0.0f;
798             testingTarget.MaxValue = 100.0f;
799             testingTarget.BgTrackColor = Color.Cyan; 
800             testingTarget.LowIndicatorImageURL = image_path;
801             testingTarget.LowIndicatorSize = new Size(8, 8);
802             testingTarget.HighIndicatorImageURL = image_path;
803             testingTarget.HighIndicatorSize = new Size(10, 10);
804
805             SliderStyle style1 = new SliderStyle()
806             {
807                 IndicatorType = Slider.IndicatorType.Image,
808             };
809             testingTarget.ApplyStyle(style1);
810
811             try
812             {
813                 testingTarget.MyOnUpdate();
814             }
815             catch (Exception e)
816             {
817                 tlog.Debug(tag, e.Message.ToString());
818                 Assert.Fail("Caught Exception : Failed!");
819             }
820
821             SliderStyle style2 = new SliderStyle()
822             {
823                 IndicatorType = Slider.IndicatorType.Text,
824             };
825             testingTarget.ApplyStyle(style2);
826
827             try
828             {
829                 testingTarget.MyOnUpdate();
830             }
831             catch (Exception e)
832             {
833                 tlog.Debug(tag, e.Message.ToString());
834                 Assert.Fail("Caught Exception : Failed!");
835             }
836
837             testingTarget.Dispose();
838             tlog.Debug(tag, $"SliderOnUpdateDirectionIsHorizontal END (OK)");
839         }
840     }
841 }