2 Copyright (c) 2013 Samsung Electronics Co., Ltd.
4 Licensed under the Apache License, Version 2.0 (the License);
5 you may not use this file except in compliance with the License.
6 You may obtain a copy of the License at
8 http://www.apache.org/licenses/LICENSE-2.0
10 Unless required by applicable law or agreed to in writing, software
11 distributed under the License is distributed on an "AS IS" BASIS,
12 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 See the License for the specific language governing permissions and
14 limitations under the License.
17 Krzysztof Lachacz <k.lachacz@samsung.com>
18 Junghyuk Park <junghyuk.park@samsung.com>
23 var reqAppControl = tizen.application.getCurrentApplication().getRequestedAppControl(),
26 assert_true("appControl" in reqAppControl, "RequestedApplicationControl should have appControl attribute");
28 appControl = reqAppControl.appControl;
29 assert_type(appControl, "object", "incorrect type of appControl");
30 assert_true("operation" in appControl, "ApplicationControl should have operation attribute");
31 assert_true("uri" in appControl, "ApplicationControl should have uri attribute");
32 assert_true("mime" in appControl, "ApplicationControl should have mime attribute");
33 assert_true("category" in appControl, "ApplicationControl should have category attribute");
34 assert_true("data" in appControl, "ApplicationControl should have data attribute");
36 reqAppControl.appControl = {
44 assert_equals(reqAppControl.appControl.operation, appControl.operation, "appControl is not readonly");
45 assert_equals(reqAppControl.appControl.uri, appControl.uri, "appControl is not readonly");
46 assert_equals(reqAppControl.appControl.mime, appControl.mime, "appControl is not readonly");
47 assert_equals(reqAppControl.appControl.category, appControl.category, "appControl is not readonly");
49 assert_equals(reqAppControl.appControl.data.length, appControl.data.length, "appControl is not readonly");
51 assert_equals(reqAppControl.appControl.data, appControl.data, "appControl is not readonly");
54 }, "Application_getRequestedAppControl");