1b1e3d1f80e0377be8ceae62435879083a08133c
[test/tct/web/api.git] /
1 <!DOCTYPE html>
2
3 <!--
4
5 Copyright (c) 2016 Samsung Electronics Co., Ltd.
6
7 Licensed under the Apache License, Version 2.0 (the License);
8 you may not use this file except in compliance with the License.
9 You may obtain a copy of the License at
10
11     http://www.apache.org/licenses/LICENSE-2.0
12
13 Unless required by applicable law or agreed to in writing, software
14 distributed under the License is distributed on an "AS IS" BASIS,
15 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 See the License for the specific language governing permissions and
17 limitations under the License.
18
19 Authors:
20         Xiaoyan Qian <xy.qian@samsung.com>
21
22 -->
23 <html>
24 <head>
25 <title>ApplicationManager_launchAppControl_errorCallback_invoked_NotFoundError</title>
26 <meta charset="utf-8">
27 <script src="support/unitcommon.js"></script>
28 <script src="support/app_common.js"></script>
29 </head>
30 <body>
31 <div id="log"></div>
32 <script>
33 //==== TEST: ApplicationManager_launchAppControl_errorCallback_invoked_NotFoundError
34 //==== LABEL Check exception in error callback of launchAppControl() method
35 //==== SPEC Tizen Web API:Application:Application:ApplicationManager:launchAppControl M
36 //==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/application.html
37 //==== PRIORITY P2
38 //==== ONLOAD_DELAY 30
39 //==== TEST_CRITERIA MERRCB
40
41 setup({timeout: 30000});
42
43 var t = async_test(document.title, {timeout: 30000}), launchSuccess, launchError;
44
45 setup_launch(t, TCT_APPCONTROL_APPID, function () {
46     launchSuccess = t.step_func(function () {
47         assert_unreached("this function should not be used");
48     });
49
50     launchError = t.step_func(function (error) {
51         assert_equals(error.name, "NotFoundError", "NotFoundError must be thrown");
52         t.done();
53     });
54
55     tizen.application.launchAppControl(new tizen.ApplicationControl("http://tizen.org/appcontrol/operation/view", "invalid", "video/divx", null), null, launchSuccess, launchError);
56 });
57
58 </script>
59 </body>
60 </html>