2
* Copyright 2012 Canonical Ltd.
4
* This program is free software: you can redistribute it and/or modify it
5
* under the terms of the GNU General Public License version 3, as published
6
* by the Free Software Foundation.
8
* This program is distributed in the hope that it will be useful, but
9
* WITHOUT ANY WARRANTY; without even the implied warranties of
10
* MERCHANTABILITY, SATISFACTORY QUALITY or FITNESS FOR A PARTICULAR
11
* PURPOSE. See the GNU General Public License for more details.
13
* You should have received a copy of the GNU General Public License
14
* version 3 along with this program. If not, see
15
* <http://www.gnu.org/licenses/>
17
* Authored by: Marco Trevisan (Treviño) <marco.trevisan@canonical.com>
20
#include <gmock/gmock.h>
22
#include "BFBLauncherIcon.h"
24
using namespace unity;
25
using namespace unity::launcher;
30
class MockBFBLauncherIcon : public BFBLauncherIcon
34
: BFBLauncherIcon(LauncherHideMode::LAUNCHER_HIDE_NEVER)
37
AbstractLauncherIcon::MenuItemsVector GetMenus()
39
return BFBLauncherIcon::GetMenus();
43
TEST(TestBFBLauncherIcon, OverlayMenus)
45
MockBFBLauncherIcon bfb;
47
for (auto menu_item : bfb.GetMenus())
49
bool overlay_item = dbusmenu_menuitem_property_get_bool(menu_item, QuicklistMenuItem::OVERLAY_MENU_ITEM_PROPERTY);
50
ASSERT_TRUE(overlay_item);