Lines Matching refs:Assert
21 import junit.framework.Assert;
48 Assert.assertEquals(id, item.getItemId());
49 Assert.assertEquals(item, mMenu.findItem(id));
50 Assert.assertEquals(0, mMenu.findItemIndex(id));
64 Assert.assertEquals(groupId, item.getGroupId());
65 Assert.assertEquals(groupId, item2.getGroupId());
66 Assert.assertEquals(item1Index, mMenu.findGroupIndex(groupId));
67 Assert.assertEquals(item2Index, mMenu.findGroupIndex(groupId, item1Index + 1));
81 Assert.assertEquals(mMenu.findGroupIndex(GROUP_ONE), 0);
82 Assert.assertEquals(mMenu.findGroupIndex(GROUP_TWO), -1);
91 Assert.assertTrue(mMenu.isShortcutKey(KeyEvent.KEYCODE_A,
93 Assert.assertFalse(mMenu.isShortcutKey(KeyEvent.KEYCODE_B,
101 Assert.assertTrue(mMenu.isShortcutKey(KeyEvent.KEYCODE_2,
103 Assert.assertFalse(mMenu.isShortcutKey(KeyEvent.KEYCODE_A,
111 Assert.assertTrue(mMenu.isShortcutKey(KeyEvent.KEYCODE_A,
114 Assert.assertFalse(mMenu.isShortcutKey(KeyEvent.KEYCODE_A,
123 Assert.assertFalse(mMenu.isShortcutKey(KeyEvent.KEYCODE_A,
132 Assert.assertFalse(mMenu.isShortcutKey(KeyEvent.KEYCODE_A,
141 Assert.assertTrue(mMenu.isShortcutKey(KeyEvent.KEYCODE_A,
149 Assert.assertTrue(mMenu.isShortcutKey(KeyEvent.KEYCODE_DEL,
157 Assert.assertTrue(mMenu.isShortcutKey(KeyEvent.KEYCODE_ENTER,
170 Assert.assertEquals(firstOrder, mMenu.getItem(0).getOrder());
171 Assert.assertEquals(a, mMenu.getItem(0).getTitle());
172 Assert.assertEquals(midOrder, mMenu.getItem(1).getOrder());
173 Assert.assertEquals(b, mMenu.getItem(1).getTitle());
174 Assert.assertEquals(lastOrder, mMenu.getItem(2).getOrder());
175 Assert.assertEquals(c, mMenu.getItem(2).getTitle());
184 Assert.assertEquals(title, stringItem.getTitle());
185 Assert.assertEquals(getContext().getResources().getString(R.string.menu_test), resItem
197 Assert.assertTrue("Item was not set to checkable", item1.isCheckable());
199 Assert.assertTrue("Item did not get checked", item1.isChecked());
200 Assert.assertFalse("Item was not unchecked due to exclusive checkable", item2.isChecked());
202 Assert.assertTrue("Item did not get checked", item2.isChecked());
203 Assert.assertFalse("Item was not unchecked due to exclusive checkable", item1.isChecked());
207 Assert.assertTrue("Item was not set to checkable", item1.isCheckable());
209 Assert.assertFalse("Item did not get unchecked", item1.isChecked());
211 Assert.assertTrue("Item did not get checked", item1.isChecked());
213 Assert.assertTrue("Item did not get checked", item2.isChecked());
214 Assert.assertTrue("Item was unchecked when it shouldnt have been", item1.isChecked());
223 Assert.assertTrue("Item did not start as visible", item1.isVisible());
224 Assert.assertTrue("Item did not start as visible", item2.isVisible());
228 Assert.assertFalse("Item did not become invisible", item1.isVisible());
230 Assert.assertFalse("Item did not become invisible", item2.isVisible());
241 Assert.assertEquals(item1, mMenu.findItem(1));
242 Assert.assertEquals(item2, mMenu.findItem(2));
255 Assert.assertEquals(item1, mMenu.findItem(1));
257 Assert.assertNull(mMenu.findItem(1));
259 Assert.assertEquals(item2, mMenu.findItem(2));
261 Assert.assertNull(mMenu.findItem(2));
263 Assert.assertEquals(item3, mMenu.findItem(3));
264 Assert.assertEquals(item4, mMenu.findItem(4));
265 Assert.assertEquals(item5, mMenu.findItem(5));
267 Assert.assertNull(mMenu.findItem(3));
268 Assert.assertNull(mMenu.findItem(4));
269 Assert.assertNull(mMenu.findItem(5));
271 Assert.assertEquals(item6, mMenu.findItem(6));
273 Assert.assertNull(mMenu.findItem(6));