3 using NUnit.Framework.TUnit;
4 using Tizen.NUI.Components;
5 using Tizen.NUI.BaseComponents;
7 namespace Tizen.NUI.Devel.Tests
9 using tlog = Tizen.Log;
12 [Description("internal/Common/CustomActorImpl")]
13 public class InternalCustomActorImplTest
15 private const string tag = "NUITEST";
16 private View actor = null;
18 internal class MyCustomActorImpl : CustomActorImpl
20 public MyCustomActorImpl(global::System.IntPtr cPtr, bool cMemoryOwn) : base(cPtr, cMemoryOwn)
28 tlog.Info(tag, "Init() is called!");
29 actor = new View() { Size = new Size(100, 200) };
36 tlog.Info(tag, "Destroy() is called!");
41 [Description("CustomActorImpl constructor.")]
42 [Property("SPEC", "Tizen.NUI.CustomActorImpl.CustomActorImpl C")]
43 [Property("SPEC_URL", "-")]
44 [Property("CRITERIA", "CONSTR")]
45 [Property("AUTHOR", "guowei.wang@samsung.com")]
46 public void CustomActorImplConstructor()
48 tlog.Debug(tag, $"CustomActorImplConstructor START");
50 var testingTarget = new CustomActorImpl(actor.SwigCPtr.Handle, false);
51 Assert.IsNotNull(testingTarget, "Should be not null!");
52 Assert.IsInstanceOf<CustomActorImpl>(testingTarget, "Should be an Instance of CustomActorImpl!");
54 testingTarget.Dispose();
55 tlog.Debug(tag, $"CustomActorImplConstructor END (OK)");
60 [Description("CustomActorImpl IsRelayoutEnabled.")]
61 [Property("SPEC", "Tizen.NUI.CustomActorImpl.IsRelayoutEnabled M")]
62 [Property("SPEC_URL", "-")]
63 [Property("CRITERIA", "MR")]
64 [Property("AUTHOR", "guowei.wang@samsung.com")]
65 public void CustomActorImplIsRelayoutEnabled()
67 tlog.Debug(tag, $"CustomActorImplIsRelayoutEnabled START");
69 var testingTarget = new CustomActorImpl(actor.SwigCPtr.Handle, false);
70 Assert.IsNotNull(testingTarget, "Should be not null!");
71 Assert.IsInstanceOf<CustomActorImpl>(testingTarget, "Should be an Instance of CustomActorImpl!");
73 var result = testingTarget.IsRelayoutEnabled();
74 tlog.Debug(tag, "IsRelayoutEnabled : " + result);
76 testingTarget.Dispose();
77 tlog.Debug(tag, $"CustomActorImplIsRelayoutEnabled END (OK)");