/cts/tools/vm-tests/src/dot/junit/ |
H A D | DxAbstractMain.java | 21 static public void assertEquals(int expected, int actual) { argument 22 if (expected != actual) throw new RuntimeException("AssertionFailedError: not equals. Expected " + expected + " actual " + actual); 25 static public void assertEquals(String message, int expected, int actual) { argument 26 if (expected != actual) throw new RuntimeException("AssertionFailedError: not equals: " + message + " Expected " + expected + " actual " + actual); 30 static public void assertEquals(long expected, long actual) { argument 31 if (expected != actual) throw new RuntimeException("AssertionFailedError: not equals. Expected " + expected + " actual " + actual); 34 static public void assertEquals(double expected, doubl argument 38 assertEquals(Object expected, Object actual) argument [all...] |
/cts/tools/dx-tests/src/dxc/junit/ |
H A D | DxAbstractMain.java | 20 static public void assertEquals(int expected, int actual) { argument 21 if (expected != actual) throw new RuntimeException("AssertionFailedError: not equals"); 24 static public void assertEquals(long expected, long actual) { argument 25 if (expected != actual) throw new RuntimeException("AssertionFailedError: not equals"); 28 static public void assertEquals(double expected, double actual, double delta) { argument 29 if(!(Math.abs(expected-actual) <= delta)) throw new RuntimeException("AssertionFailedError: not within delta"); 32 static public void assertEquals(Object expected, Object actual) { argument 33 if (expected == null && actual == null) 35 if (expected != null && expected [all...] |
/cts/tests/tests/content/src/android/content/pm/cts/ |
H A D | PackageInfoTest.java | 95 private void checkPkgInfoSame(PackageInfo expected, PackageInfo actual) { argument 96 assertEquals(expected.packageName, actual.packageName); 97 assertEquals(expected.versionCode, actual.versionCode); 98 assertEquals(expected.versionName, actual.versionName); 99 assertEquals(expected.sharedUserId, actual.sharedUserId); 100 assertEquals(expected.sharedUserLabel, actual.sharedUserLabel); 101 if (expected.applicationInfo != null) { 103 checkAppInfo(expected.applicationInfo, actual.applicationInfo); 107 assertTrue(Arrays.equals(expected.gids, actual.gids)); 108 checkInfoArray(expected 119 checkAppInfo(ApplicationInfo expected, ApplicationInfo actual) argument 136 checkInfoArray(PackageItemInfo[] expected, PackageItemInfo[] actual) argument 150 checkSignatureInfo(Signature[] expected, Signature[] actual) argument 164 checkConfigInfo(ConfigurationInfo[] expected, ConfigurationInfo[] actual) argument [all...] |
H A D | ProviderInfoTest.java | 107 private void checkInfoSame(ProviderInfo expected, ProviderInfo actual) { argument 108 assertEquals(expected.name, actual.name); 109 assertEquals(expected.authority, actual.authority); 110 assertEquals(expected.readPermission, actual.readPermission); 111 assertEquals(expected.writePermission, actual.writePermission); 112 assertEquals(expected.grantUriPermissions, actual.grantUriPermissions); 113 assertEquals(expected.uriPermissionPatterns, actual.uriPermissionPatterns); 114 assertEquals(expected.multiprocess, actual.multiprocess); 115 assertEquals(expected.initOrder, actual.initOrder); 116 assertEquals(expected [all...] |
H A D | InstrumentationInfoTest.java | 92 private void checkInfoSame(InstrumentationInfo expected, InstrumentationInfo actual) { argument 93 assertEquals(expected.name, actual.name); 94 assertEquals(expected.dataDir, actual.dataDir); 95 assertEquals(expected.handleProfiling, actual.handleProfiling); 96 assertEquals(expected.functionalTest, actual.functionalTest); 97 assertEquals(expected.targetPackage, actual.targetPackage); 98 assertEquals(expected.sourceDir, actual.sourceDir); 99 assertEquals(expected.publicSourceDir, actual.publicSourceDir);
|
H A D | PackageStatsTest.java | 99 private void checkInfoSame(PackageStats expected, PackageStats actual) { argument 100 assertEquals(expected.packageName, actual.packageName); 101 assertEquals(expected.cacheSize, actual.cacheSize); 102 assertEquals(expected.dataSize, actual.dataSize); 103 assertEquals(expected.codeSize, actual.codeSize);
|
H A D | PermissionInfoTest.java | 95 private void checkInfoSame(PermissionInfo expected, PermissionInfo actual) { argument 96 assertEquals(expected.name, actual.name); 97 assertEquals(expected.group, actual.group); 98 assertEquals(expected.descriptionRes, actual.descriptionRes); 99 assertEquals(expected.protectionLevel, actual.protectionLevel); 100 assertEquals(expected.nonLocalizedDescription, actual.nonLocalizedDescription);
|
/cts/tests/tests/content/src/android/content/res/cts/ |
H A D | ArrayTest.java | 35 final Object expected) { 37 + " at index " + index, expected, res); 40 private void checkStringArray(final int resid, final String[] expected) { argument 42 assertEquals(res.length, expected.length); 43 for (int i = 0; i < expected.length; i++) { 44 checkEntry(resid, i, res[i], expected[i]); 48 private void checkTextArray(final int resid, final String[] expected) { argument 50 assertEquals(res.length, expected.length); 51 for (int i = 0; i < expected.length; i++) { 52 checkEntry(resid, i, res[i], expected[ 34 checkEntry(final int resid, final int index, final Object res, final Object expected) argument 56 checkIntArray(final int resid, final int[] expected) argument [all...] |
H A D | PrimitiveTest.java | 35 private void tryEnum(final int resid, final int expected) { argument 40 assertEquals("Expecting value " + expected + " got " + value 41 + ": in resource 0x" + Integer.toHexString(resid), expected, value); 52 private void tryFlag(final int resid, final int expected) { argument 57 assertEquals("Expecting value " + expected + " got " + value 58 + ": in resource 0x" + Integer.toHexString(resid), expected, value); 70 private void tryBoolean(final int resid, final boolean expected) { argument 74 assertEquals("Expecting boolean value " + expected + " got " + v 76 expected, v.data != 0); 77 assertEquals("Expecting boolean value " + expected 88 tryString(final int resid, final String expected) argument 107 checkString(final int resid, final String actual, final String expected) argument [all...] |
/cts/tests/tests/content/src/android/content/cts/ |
H A D | ContentValuesTest.java | 74 // expected, test success. 81 // expected, test success. 131 Long expected = 10L; 132 mContentValues.put("Long", expected); 133 assertEquals(expected, mContentValues.getAsLong("Long")); 135 expected = -1000L; 136 mContentValues.put("Long", expected); 137 assertEquals(expected, mContentValues.getAsLong("Long")); 150 Byte expected = 'a'; 151 mContentValues.put("Byte", expected); [all...] |
H A D | IntentTest.java | 180 final CharSequence expected = "CharSequencetest"; 181 mIntent.putExtra(TEST_EXTRA_NAME, expected); 182 assertEquals(expected, mIntent.getCharSequenceExtra(TEST_EXTRA_NAME)); 261 final ArrayList<Intent> expected = new ArrayList<Intent>(); 263 expected.add(intent); 265 mIntent.putParcelableArrayListExtra(TEST_EXTRA_NAME, expected); 267 assertEquals(expected.size(), target.size()); 268 assertEquals(expected, target); 329 final ArrayList<Integer> expected = new ArrayList<Integer>(); 330 expected [all...] |
H A D | ContentUrisTest.java | 82 //expected, test success. 92 // expected, test success. 103 String expected = "content://" + AUTHORITY + "/" + PATH1 + "/" + CODE1; 107 assertEquals(expected, actually.toString()); 109 expected = "content://" + AUTHORITY + "/" + PATH2 + "/" + CODE2; 111 assertEquals(expected, actually.toString()); 126 // expected, test success. 137 String expected = "content://" + AUTHORITY + "/" + PATH1 + "/" + CODE1; 142 assertEquals(expected, actually.toString()); 144 expected [all...] |
/cts/tests/tests/net/src/android/net/cts/ |
H A D | NetworkInfo_DetailedStateTest.java | 54 DetailedState[] expected = DetailedState.values(); 55 assertEquals(10, expected.length); 56 assertEquals(DetailedState.IDLE, expected[0]); 57 assertEquals(DetailedState.SCANNING, expected[1]); 58 assertEquals(DetailedState.CONNECTING, expected[2]); 59 assertEquals(DetailedState.AUTHENTICATING, expected[3]); 60 assertEquals(DetailedState.OBTAINING_IPADDR, expected[4]); 61 assertEquals(DetailedState.CONNECTED, expected[5]); 62 assertEquals(DetailedState.SUSPENDED, expected[6]); 63 assertEquals(DetailedState.DISCONNECTING, expected[ [all...] |
H A D | NetworkInfo_StateTest.java | 50 State[] expected = State.values(); 51 assertEquals(6, expected.length); 52 assertEquals(State.CONNECTING, expected[0]); 53 assertEquals(State.CONNECTED, expected[1]); 54 assertEquals(State.SUSPENDED, expected[2]); 55 assertEquals(State.DISCONNECTING, expected[3]); 56 assertEquals(State.DISCONNECTED, expected[4]); 57 assertEquals(State.UNKNOWN, expected[5]);
|
H A D | LocalSocketAddress_NamespaceTest.java | 47 Namespace[] expected = Namespace.values(); 48 assertEquals(Namespace.ABSTRACT, expected[0]); 49 assertEquals(Namespace.RESERVED, expected[1]); 50 assertEquals(Namespace.FILESYSTEM, expected[2]);
|
/cts/tests/src/android/text/method/cts/ |
H A D | TextMethodUtils.java | 27 * @param expected the expected char array. 30 public static void assertEquals(char[] expected, char[] actual) { argument 31 if (expected != actual) { 32 if (expected == null || actual == null) { 36 Assert.assertEquals(String.valueOf(expected), String.valueOf(actual));
|
/cts/tests/tests/graphics/src/android/graphics/cts/ |
H A D | Region_OpTest.java | 52 // set the expected value 53 Op[] expected = { 61 assertEquals(expected.length, actual.length); 62 assertEquals(expected[0], actual[0]); 63 assertEquals(expected[1], actual[1]); 64 assertEquals(expected[2], actual[2]); 65 assertEquals(expected[3], actual[3]); 66 assertEquals(expected[4], actual[4]); 67 assertEquals(expected[5], actual[5]);
|
H A D | Path_DirectionTest.java | 46 // set the expected value 47 Direction[] expected = { 51 assertEquals(expected.length, actual.length); 53 assertEquals(expected[i], actual[i]);
|
H A D | NinePatchTest.java | 115 Bitmap expected = BitmapFactory.decodeResource(mRes, R.drawable.scaled1, mOptNoScale); 117 Bitmap bitmap = Bitmap.createBitmap(expected.getWidth(), expected.getHeight(), 122 checkBitmapWithAlpha(expected, bitmap, ALPHA_OPAQUE); 124 expected = BitmapFactory.decodeResource(mRes, R.drawable.scaled2, mOptNoScale); 125 bitmap = Bitmap.createBitmap(expected.getWidth(), expected.getHeight(), 130 checkBitmapWithAlpha(expected, bitmap, ALPHA_OPAQUE); 132 bitmap = Bitmap.createBitmap(expected.getWidth(), expected 151 checkBitmapWithAlpha(Bitmap expected, Bitmap bitmap, int alpha) argument [all...] |
/cts/tests/tests/widget/src/android/widget/cts/ |
H A D | ChronometerTest.java | 87 int expected = 100000; 88 chronometer.setBase(expected); 89 assertEquals(expected, chronometer.getBase()); 92 expected = 100; 94 chronometer.setBase(expected); 95 assertEquals(expected, chronometer.getBase()); 98 expected = -1; 100 chronometer.setBase(expected); 101 assertEquals(expected, chronometer.getBase()); 104 expected [all...] |
/cts/tests/tests/os/src/android/os/cts/ |
H A D | MessageTest.java | 120 Message expected = Message.obtain(mHandler, mRunnable); 121 assertEquals(mRunnable, expected.getCallback()); 161 Message expected = Message.obtain(message); 163 assertEquals(message.getTarget(), expected.getTarget()); 164 assertEquals(message.what, expected.what); 165 assertEquals(message.arg1, expected.arg1); 166 assertEquals(message.arg2, expected.arg2); 167 assertEquals(message.obj, expected.obj); 177 Message expected = Message.obtain(mHandler); 178 assertEquals(mHandler, expected [all...] |
H A D | FileObserverTest.java | 134 int[] expected = null; 145 expected = new int[] {FileObserver.MODIFY, FileObserver.OPEN, FileObserver.MODIFY, 148 assertEventsEquals(expected, moveEvents); 156 expected = new int[] {UNDEFINED}; 158 assertEventsEquals(expected, moveEvents); 174 expected = new int[] {FileObserver.CREATE, 178 assertEventsEquals(expected, moveEvents); 198 expected = new int[] {FileObserver.MOVE_SELF}; 200 assertEventsEquals(expected, moveEvents); 202 expected 219 assertEventsEquals(final int[] expected, final FileEvent[] moveEvents) argument [all...] |
/cts/tests/tests/provider/src/android/provider/cts/ |
H A D | Settings_SecureTest.java | 62 } catch (NumberFormatException expected) { 95 } catch (SecurityException expected) { 101 } catch (SettingNotFoundException expected) { 107 } catch (SettingNotFoundException expected) { 117 } catch (SecurityException expected) { 124 } catch (NullPointerException expected) { 130 } catch (SettingNotFoundException expected) { 140 } catch (SecurityException expected) { 146 } catch (SettingNotFoundException expected) { 152 } catch (SettingNotFoundException expected) { [all...] |
/cts/tests/tests/database/src/android/database/sqlite/cts/ |
H A D | SQLiteQueryBuilderTest.java | 96 String expected; 104 expected = "SELECT age, address FROM " + TEST_TABLE_NAME + " WHERE (age=20)"; 105 assertEquals(expected, sql); 114 expected = "SELECT DISTINCT age, address FROM " + EMPLOYEE_TABLE_NAME + " WHERE (age>32)"; 115 assertEquals(expected, sql); 124 expected = "SELECT DISTINCT age, address FROM " + EMPLOYEE_TABLE_NAME 126 assertEquals(expected, sql); 135 String expected; 146 expected = "SELECT name, age FROM " + TEST_TABLE_NAME; 147 assertEquals(expected, sq [all...] |
/cts/tests/tests/text/src/android/text/cts/ |
H A D | Editable_FactoryTest.java | 41 // set the expected value 42 Editable expected = new SpannableStringBuilder(source); 47 assertEquals(expected.toString(), actual.toString());
|