2 * Copyright (c) 2017 Samsung Electronics Co., Ltd
4 * Licensed under the Flora License, Version 1.1 (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://floralicense.org/license/
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 using Microsoft.VisualStudio.TestTools.UnitTesting;
18 using LibTVRefCommonPortable.Models;
20 namespace HomeUnitTest
23 /// A Test cases for ManagedApps class.
26 public class ManagedAppsTestCases
31 private static readonly string Home = "org.tizen.xahome";
36 private static readonly string Apps = "org.tizen.xaapps";
39 /// Mediahub package ID
41 private static readonly string Mediahub = "org.tizen.xamediahub";
44 /// Settings package ID
46 private static readonly string Settings = "org.tizen.settings";
49 public void ManagerAppsIsHiddenRecentAppTest()
51 Assert.IsTrue(ManagedApps.IsHiddenRecentApp(Home), "TVHome should not be hidden in Recents");
52 Assert.IsTrue(ManagedApps.IsHiddenRecentApp(Apps), "Apps should not be hidden in Recents");
53 Assert.IsTrue(ManagedApps.IsHiddenRecentApp(Mediahub), "Mediahub should not be hidden in Recents");
54 Assert.IsTrue(ManagedApps.IsHiddenRecentApp(Settings), "Settings should not be hidden in Recents");
58 public void ManagerAppsIsNonPinnableAppsTest()
60 Assert.IsTrue(ManagedApps.IsNonPinnableApps(Home), "TVHome should not be pinned");
61 Assert.IsTrue(ManagedApps.IsNonPinnableApps(Apps), "Apps should not be pinned");
62 Assert.IsTrue(ManagedApps.IsNonPinnableApps(Mediahub), "Mediahub should not be pinned");
63 Assert.IsTrue(ManagedApps.IsNonPinnableApps(Settings), "Settings should not be pinned");