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/WebView/WebViewResponsePolicyDecidedEventArgs")]
13 public class InternalWebViewResponsePolicyDecidedEventArgsTest
15 private const string tag = "NUITEST";
16 private string url = Tizen.Applications.Application.Current.DirectoryInfo.Resource + "picture.png";
21 tlog.Info(tag, "Init() is called!");
27 tlog.Info(tag, "Destroy() is called!");
32 [Description("WebViewResponsePolicyDecidedEventArgs constructor.")]
33 [Property("SPEC", "Tizen.NUI.WebViewResponsePolicyDecidedEventArgs.WebViewResponsePolicyDecidedEventArgs C")]
34 [Property("SPEC_URL", "-")]
35 [Property("CRITERIA", "CONSTR")]
36 [Property("COVPARAM", "")]
37 [Property("AUTHOR", "guowei.wang@samsung.com")]
38 public void WebViewResponsePolicyDecidedEventArgsConstructor()
40 tlog.Debug(tag, $"WebViewResponsePolicyDecidedEventArgsConstructor START");
42 using (Tizen.NUI.BaseComponents.WebView webview = new Tizen.NUI.BaseComponents.WebView("Shanghai", "Asia/Shanghai"))
44 WebPolicyDecisionMaker maker = new WebPolicyDecisionMaker(webview.SwigCPtr.Handle, false);
46 var testingTarget = new WebViewResponsePolicyDecidedEventArgs(maker);
47 Assert.IsNotNull(testingTarget, "null handle");
48 Assert.IsInstanceOf<WebViewResponsePolicyDecidedEventArgs>(testingTarget, "Should return WebViewResponsePolicyDecidedEventArgs instance.");
53 tlog.Debug(tag, $"WebViewResponsePolicyDecidedEventArgsConstructor END (OK)");
58 [Description("WebViewResponsePolicyDecidedEventArgs ResponsePolicyDecisionMaker.")]
59 [Property("SPEC", "Tizen.NUI.WebViewResponsePolicyDecidedEventArgs.ResponsePolicyDecisionMaker A")]
60 [Property("SPEC_URL", "-")]
61 [Property("CRITERIA", "PRO")]
62 [Property("COVPARAM", "")]
63 [Property("AUTHOR", "guowei.wang@samsung.com")]
64 public void WebViewResponsePolicyDecidedEventArgsResponsePolicyDecisionMaker()
66 tlog.Debug(tag, $"WebViewResponsePolicyDecidedEventArgsResponsePolicyDecisionMaker START");
68 using (Tizen.NUI.BaseComponents.WebView webview = new Tizen.NUI.BaseComponents.WebView("Shanghai", "Asia/Shanghai"))
70 WebPolicyDecisionMaker maker = new WebPolicyDecisionMaker(webview.SwigCPtr.Handle, false);
72 var testingTarget = new WebViewResponsePolicyDecidedEventArgs(maker);
73 Assert.IsNotNull(testingTarget, "null handle");
74 Assert.IsInstanceOf<WebViewResponsePolicyDecidedEventArgs>(testingTarget, "Should return WebViewResponsePolicyDecidedEventArgs instance.");
76 var result = testingTarget.ResponsePolicyDecisionMaker;
77 tlog.Debug(tag, "ResponsePolicyDecisionMaker : " + result);
82 tlog.Debug(tag, $"WebViewResponsePolicyDecidedEventArgsResponsePolicyDecisionMaker END (OK)");