diff options
Diffstat (limited to 'tests/permission/src/com/android/framework/permission/tests/WindowManagerPermissionTests.java')
-rw-r--r-- | tests/permission/src/com/android/framework/permission/tests/WindowManagerPermissionTests.java | 101 |
1 files changed, 0 insertions, 101 deletions
diff --git a/tests/permission/src/com/android/framework/permission/tests/WindowManagerPermissionTests.java b/tests/permission/src/com/android/framework/permission/tests/WindowManagerPermissionTests.java index 58f65be..1f6279c 100644 --- a/tests/permission/src/com/android/framework/permission/tests/WindowManagerPermissionTests.java +++ b/tests/permission/src/com/android/framework/permission/tests/WindowManagerPermissionTests.java @@ -255,41 +255,6 @@ public class WindowManagerPermissionTests extends TestCase { } @SmallTest - public void testINJECT_EVENTS() { - try { - mWm.injectKeyEvent(new KeyEvent(0, 0), false); - fail("IWindowManager.injectKeyEvent did not throw SecurityException as" - + " expected"); - } catch (SecurityException e) { - // expected - } catch (RemoteException e) { - fail("Unexpected remote exception"); - } - - try { - mWm.injectPointerEvent(MotionEvent.obtain(0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0), false); - fail("IWindowManager.injectPointerEvent did not throw SecurityException as" - + " expected"); - } catch (SecurityException e) { - // expected - } catch (RemoteException e) { - fail("Unexpected remote exception"); - } - - try { - mWm.injectTrackballEvent(MotionEvent.obtain(0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0), false); - fail("IWindowManager.injectTrackballEvent did not throw SecurityException as" - + " expected"); - } catch (SecurityException e) { - // expected - } catch (RemoteException e) { - fail("Unexpected remote exception"); - } - } - - @SmallTest public void testDISABLE_KEYGUARD() { Binder token = new Binder(); try { @@ -347,73 +312,9 @@ public class WindowManagerPermissionTests extends TestCase { } @SmallTest - public void testREAD_INPUT_STATE() { - try { - mWm.getSwitchState(0); - fail("IWindowManager.getSwitchState did not throw SecurityException as" - + " expected"); - } catch (SecurityException e) { - // expected - } catch (RemoteException e) { - fail("Unexpected remote exception"); - } - - try { - mWm.getSwitchStateForDevice(0, 0); - fail("IWindowManager.getSwitchStateForDevice did not throw SecurityException as" - + " expected"); - } catch (SecurityException e) { - // expected - } catch (RemoteException e) { - fail("Unexpected remote exception"); - } - - try { - mWm.getScancodeState(0); - fail("IWindowManager.getScancodeState did not throw SecurityException as" - + " expected"); - } catch (SecurityException e) { - // expected - } catch (RemoteException e) { - fail("Unexpected remote exception"); - } - - try { - mWm.getScancodeStateForDevice(0, 0); - fail("IWindowManager.getScancodeStateForDevice did not throw SecurityException as" - + " expected"); - } catch (SecurityException e) { - // expected - } catch (RemoteException e) { - fail("Unexpected remote exception"); - } - - try { - mWm.getKeycodeState(0); - fail("IWindowManager.getKeycodeState did not throw SecurityException as" - + " expected"); - } catch (SecurityException e) { - // expected - } catch (RemoteException e) { - fail("Unexpected remote exception"); - } - - try { - mWm.getKeycodeStateForDevice(0, 0); - fail("IWindowManager.getKeycodeStateForDevice did not throw SecurityException as" - + " expected"); - } catch (SecurityException e) { - // expected - } catch (RemoteException e) { - fail("Unexpected remote exception"); - } - } - - @SmallTest public void testSET_ORIENTATION() { try { mWm.updateRotation(true, false); - mWm.getSwitchState(0); fail("IWindowManager.updateRotation did not throw SecurityException as" + " expected"); } catch (SecurityException e) { @@ -424,7 +325,6 @@ public class WindowManagerPermissionTests extends TestCase { try { mWm.freezeRotation(-1); - mWm.getSwitchState(0); fail("IWindowManager.freezeRotation did not throw SecurityException as" + " expected"); } catch (SecurityException e) { @@ -435,7 +335,6 @@ public class WindowManagerPermissionTests extends TestCase { try { mWm.thawRotation(); - mWm.getSwitchState(0); fail("IWindowManager.thawRotation did not throw SecurityException as" + " expected"); } catch (SecurityException e) { |