[NUI] Update TCs of NUI.Devel.
[platform/core/csapi/tizenfx.git] / test / Tizen.NUI.Tests / Tizen.NUI.Devel.Tests / testcase / public / Xaml / TSProvideCompiledAttribute.cs
1 using NUnit.Framework;
2 using System;
3 using Tizen.NUI.Xaml;
4
5 namespace Tizen.NUI.Devel.Tests
6 {
7     using tlog = Tizen.Log;
8
9     [TestFixture]
10     [Description("public/xaml/ProvideCompiledAttribute")]
11     public class PublicProvideCompiledAttributeTest
12     {
13         private const string tag = "NUITEST";
14
15         [SetUp]
16         public void Init()
17         {
18             tlog.Info(tag, "Init() is called!");
19         }
20
21         [TearDown]
22         public void Destroy()
23         {
24             tlog.Info(tag, "Destroy() is called!");
25         }
26
27         [Test]
28         [Category("P1")]
29         [Description("ProvideCompiledAttribute ProvideCompiledAttribute")]
30         [Property("SPEC", "Tizen.NUI.ProvideCompiledAttribute.ProvideCompiledAttribute C")]
31         [Property("SPEC_URL", "-")]
32         [Property("CRITERIA", "CONSTR")]
33         public void ProvideCompiledAttributeConstructor()
34         {
35             tlog.Debug(tag, $"ProvideCompiledAttributeConstructor START");
36
37             var testingTarget = new ProvideCompiledAttribute("testAttribute");
38             Assert.IsNotNull(testingTarget, "null ProvideCompiledAttribute");
39             Assert.IsInstanceOf<ProvideCompiledAttribute>(testingTarget, "Should return ProvideCompiledAttribute instance.");
40             
41             testingTarget = null;
42             tlog.Debug(tag, $"ProvideCompiledAttributeConstructor END");
43         }
44
45         [Test]
46         [Category("P1")]
47         [Description("ProvideCompiledAttribute CompiledVersion")]
48         [Property("SPEC", "Tizen.NUI.ProvideCompiledAttribute.CompiledVersion A")]
49         [Property("SPEC_URL", "-")]
50         [Property("CRITERIA", "PRW")]
51         public void ProvideCompiledAttributeCompiledVersion()
52         {
53             tlog.Debug(tag, $"ProvideCompiledAttributeCompiledVersion START");
54             try
55             {
56                 var testingTarget = new ProvideCompiledAttribute("testAttribute");
57                 Assert.IsNotNull(testingTarget, "null ProvideCompiledAttribute");
58                 Assert.IsInstanceOf<ProvideCompiledAttribute>(testingTarget, "Should return ProvideCompiledAttribute instance.");
59                 
60                 string result = testingTarget.CompiledVersion;
61                 tlog.Debug(tag, "CompiledVersion : " + result);
62
63             }
64             catch (Exception e)
65             {
66                 tlog.Debug(tag, e.Message.ToString());
67                 Assert.Fail("Caught Exception : Failed!");
68             }
69             tlog.Debug(tag, $"ProvideCompiledAttributeCompiledVersion END");
70         }
71     }
72 }