/cts/tests/tests/provider/src/android/provider/cts/ |
D | MediaStore_Audio_MediaTest.java | 41 Cursor c = null; in testGetContentUri() local 42 assertNotNull(c = mContentResolver.query( in testGetContentUri() 45 c.close(); in testGetContentUri() 46 assertNotNull(c = mContentResolver.query( in testGetContentUri() 49 c.close(); in testGetContentUri() 57 Cursor c = null; in testGetContentUriForPath() local 59 … assertNotNull(c = mContentResolver.query(Media.getContentUriForPath(externalPath), null, null, in testGetContentUriForPath() 61 c.close(); in testGetContentUriForPath() 65 … assertNotNull(c = mContentResolver.query(Media.getContentUriForPath(internalPath), null, null, in testGetContentUriForPath() 67 c.close(); in testGetContentUriForPath() [all …]
|
D | MediaStore_Audio_Genres_MembersTest.java | 45 Cursor c = mContentResolver.query(uri, null, null, null, null); in setUp() local 46 c.moveToFirst(); in setUp() 47 mAudioIdOfJam = c.getLong(c.getColumnIndex(Media._ID)); in setUp() 48 c.close(); in setUp() 51 c = mContentResolver.query(uri, null, null, null, null); in setUp() 52 c.moveToFirst(); in setUp() 53 mAudioIdOfJamLive = c.getLong(c.getColumnIndex(Media._ID)); in setUp() 54 c.close(); in setUp() 68 Cursor c = null; in testGetContentUri() local 69 assertNotNull(c = mContentResolver.query( in testGetContentUri() [all …]
|
D | MediaStore_Video_MediaTest.java | 50 Cursor c = null; in testGetContentUri() local 51 assertNotNull(c = mContentResolver.query(Media.getContentUri("internal"), null, null, null, in testGetContentUri() 53 c.close(); in testGetContentUri() 54 assertNotNull(c = mContentResolver.query(Media.getContentUri("external"), null, null, null, in testGetContentUri() 56 c.close(); in testGetContentUri() 113 Cursor c = mContentResolver.query(uri, null, null, null, null); in testStoreVideoMediaExternal() local 114 assertEquals(1, c.getCount()); in testStoreVideoMediaExternal() 115 c.moveToFirst(); in testStoreVideoMediaExternal() 116 long id = c.getLong(c.getColumnIndex(Media._ID)); in testStoreVideoMediaExternal() 118 assertEquals("cts", c.getString(c.getColumnIndex(Media.ALBUM))); in testStoreVideoMediaExternal() [all …]
|
D | MediaStore_Images_MediaTest.java | 100 Cursor c = Media.query(mContentResolver, Media.EXTERNAL_CONTENT_URI, null, null, in testInsertImageWithImagePath() local 102 int previousCount = c.getCount(); in testInsertImageWithImagePath() 103 c.close(); in testInsertImageWithImagePath() 134 c = Media.query(mContentResolver, Uri.parse(stringUrl), in testInsertImageWithImagePath() 136 assertEquals(1, c.getCount()); in testInsertImageWithImagePath() 137 c.moveToFirst(); in testInsertImageWithImagePath() 138 assertEquals(TEST_TITLE2, c.getString(c.getColumnIndex(Media.TITLE))); in testInsertImageWithImagePath() 139 assertEquals(TEST_DESCRIPTION2, c.getString(c.getColumnIndex(Media.DESCRIPTION))); in testInsertImageWithImagePath() 140 assertEquals(MIME_TYPE_JPEG, c.getString(c.getColumnIndex(Media.MIME_TYPE))); in testInsertImageWithImagePath() 141 c.close(); in testInsertImageWithImagePath() [all …]
|
D | MediaStore_Audio_Playlists_MembersTest.java | 106 Cursor c = mContentResolver.query(uri, null, null, null, null); in insertAudioItem() local 107 c.moveToFirst(); in insertAudioItem() 108 long id = c.getLong(c.getColumnIndex(Media._ID)); in insertAudioItem() 109 c.close(); in insertAudioItem() 153 Cursor c = mContentResolver.query(playlistMembersUri, in verifyPlaylist() local 161 members.length, c.getCount()); in verifyPlaylist() 169 ordering.length, c.getCount()); in verifyPlaylist() 171 while (c.moveToNext()) { in verifyPlaylist() 172 int pos = c.getPosition(); in verifyPlaylist() 175 members[pos], c.getInt(c.getColumnIndex(Members.AUDIO_ID))); in verifyPlaylist() [all …]
|
D | MediaStore_Images_ThumbnailsTest.java | 78 Cursor c = Thumbnails.queryMiniThumbnails(mContentResolver, in testQueryInternalThumbnails() local 80 int previousMicroKindCount = c.getCount(); in testQueryInternalThumbnails() 81 c.close(); in testQueryInternalThumbnails() 94 c = Thumbnails.queryMiniThumbnails(mContentResolver, uri, Thumbnails.MINI_KIND, null); in testQueryInternalThumbnails() 95 c.moveToFirst(); in testQueryInternalThumbnails() 96 assertEquals(1, c.getCount()); in testQueryInternalThumbnails() 97 assertEquals(Thumbnails.MINI_KIND, c.getInt(c.getColumnIndex(Thumbnails.KIND))); in testQueryInternalThumbnails() 98 assertEquals(path, c.getString(c.getColumnIndex(Thumbnails.DATA))); in testQueryInternalThumbnails() 101 c = Thumbnails.queryMiniThumbnails(mContentResolver, Thumbnails.INTERNAL_CONTENT_URI, in testQueryInternalThumbnails() 103 assertEquals(previousMicroKindCount, c.getCount()); in testQueryInternalThumbnails() [all …]
|
D | MediaStore_Audio_Artists_AlbumsTest.java | 42 Cursor c = null; in testGetContentUri() local 45 assertNotNull(c = mContentResolver.query(contentUri, null, null, null, null)); in testGetContentUri() 46 c.close(); in testGetContentUri() 50 assertNotNull(c = mContentResolver.query(contentUri, null, null, null, null)); in testGetContentUri() 51 c.close(); in testGetContentUri() 72 Cursor c = mContentResolver.query(audioMediaUri, new String[] { Media.ARTIST_ID }, null, in testStoreAudioArtistsAlbums() local 74 c.moveToFirst(); in testStoreAudioArtistsAlbums() 75 Long artistId = c.getLong(c.getColumnIndex(Media.ARTIST_ID)); in testStoreAudioArtistsAlbums() 76 c.close(); in testStoreAudioArtistsAlbums() 90 c = mContentResolver.query(artistsAlbumsUri, null, null, null, null); in testStoreAudioArtistsAlbums() [all …]
|
D | MediaStore_Audio_AlbumsTest.java | 50 Cursor c = null; in testGetContentUri() local 51 assertNotNull(c = mContentResolver.query( in testGetContentUri() 54 c.close(); in testGetContentUri() 55 assertNotNull(c = mContentResolver.query( in testGetContentUri() 58 c.close(); in testGetContentUri() 92 Cursor c = mContentResolver.query(audioAlbumsUri, null, selection, selectionArgs, in testStoreAudioAlbums() local 94 assertEquals(1, c.getCount()); in testStoreAudioAlbums() 95 c.moveToFirst(); in testStoreAudioAlbums() 96 long id = c.getLong(c.getColumnIndex(Albums._ID)); in testStoreAudioAlbums() 98 assertEquals(Audio1.ALBUM, c.getString(c.getColumnIndex(Albums.ALBUM))); in testStoreAudioAlbums() [all …]
|
D | MediaStore_Audio_ArtistsTest.java | 40 Cursor c = null; in testGetContentUri() local 41 assertNotNull(c = mContentResolver.query( in testGetContentUri() 44 c.close(); in testGetContentUri() 45 assertNotNull(c = mContentResolver.query( in testGetContentUri() 48 c.close(); in testGetContentUri() 80 Cursor c = mContentResolver.query(artistsUri, null, selection, selectionArgs, null); in testStoreAudioArtists() local 81 assertEquals(1, c.getCount()); in testStoreAudioArtists() 82 c.moveToFirst(); in testStoreAudioArtists() 84 assertEquals(Audio1.ARTIST, c.getString(c.getColumnIndex(Artists.ARTIST))); in testStoreAudioArtists() 85 long id = c.getLong(c.getColumnIndex(Artists._ID)); in testStoreAudioArtists() [all …]
|
D | Settings_NameValueTableTest.java | 35 Cursor c = cr.query(uri, null, null, null, null); in testPutString() local 37 assertNotNull(c); in testPutString() 38 int origCount = c.getCount(); in testPutString() 39 c.close(); in testPutString() 42 c = cr.query(uri, null, null, null, null); in testPutString() 43 assertNotNull(c); in testPutString() 44 assertEquals(origCount + 1, c.getCount()); in testPutString() 45 c.close(); in testPutString() 49 c = cr.query(uri, null, selection, null, null); in testPutString() 50 assertNotNull(c); in testPutString() [all …]
|
D | MediaStore_Audio_PlaylistsTest.java | 42 Cursor c = null; in testGetContentUri() local 43 assertNotNull(c = mContentResolver.query( in testGetContentUri() 46 c.close(); in testGetContentUri() 50 assertNotNull(c = mContentResolver.query( in testGetContentUri() 53 c.close(); in testGetContentUri() 79 Cursor c = mContentResolver.query(uri, null, null, null, null); in testStoreAudioPlaylistsExternal() local 80 assertEquals(1, c.getCount()); in testStoreAudioPlaylistsExternal() 81 c.moveToFirst(); in testStoreAudioPlaylistsExternal() 82 assertEquals("My favourites", c.getString(c.getColumnIndex(Playlists.NAME))); in testStoreAudioPlaylistsExternal() 84 c.getString(c.getColumnIndex(Playlists.DATA))); in testStoreAudioPlaylistsExternal() [all …]
|
D | MediaStore_Video_ThumbnailsTest.java | 108 Cursor c = mResolver.query(Thumbnails.EXTERNAL_CONTENT_URI, in testGetThumbnail() local 112 if (c.moveToLast()) { in testGetThumbnail() 113 long vid = c.getLong(2); in testGetThumbnail() 115 String path = c.getString(1); in testGetThumbnail() 117 long id = c.getLong(0); in testGetThumbnail() 122 c.close(); in testGetThumbnail() 143 Cursor c = mResolver.query( in testThumbnailGenerationAndCleanup() local 150 assertTrue("couldn't find thumbnail", c.moveToNext()); in testThumbnailGenerationAndCleanup() 151 String path = c.getString(0); in testThumbnailGenerationAndCleanup() 152 c.close(); in testThumbnailGenerationAndCleanup() [all …]
|
/cts/tests/tests/content/src/android/content/res/cts/ |
D | ColorStateListTest.java | 41 final ColorStateList c = new ColorStateList(state, colors); in testConstructor() local 42 assertTrue(c.isStateful()); in testConstructor() 43 assertEquals(Color.RED, c.getDefaultColor()); in testConstructor() 51 final ColorStateList c = ColorStateList.createFromXml(res, res.getXml(xmlId)); in testCreateFromXml() local 52 assertEquals(colorInXml, c.getDefaultColor()); in testCreateFromXml() 53 assertEquals(0, c.describeContents()); in testCreateFromXml() 54 assertFalse(c.isStateful()); in testCreateFromXml() 55 assertNotNull(c.toString()); in testCreateFromXml() 56 assertEquals(colorInXml, c.getColorForState(new int[]{0}, 0)); in testCreateFromXml() 66 final ColorStateList c = ColorStateList.createFromXml(res, res.getXml(xmlId), theme); in testCreateFromXmlThemed() local [all …]
|
/cts/tests/tests/media/libmediandkjni/ |
D | md5_utils.cpp | 160 /*register*/ UWORD32 a, b, c, d; in MD5Transform() local 164 c = buf[2]; in MD5Transform() 167 MD5STEP(F1, a, b, c, d, in[0] + 0xd76aa478, 7); in MD5Transform() 168 MD5STEP(F1, d, a, b, c, in[1] + 0xe8c7b756, 12); in MD5Transform() 169 MD5STEP(F1, c, d, a, b, in[2] + 0x242070db, 17); in MD5Transform() 170 MD5STEP(F1, b, c, d, a, in[3] + 0xc1bdceee, 22); in MD5Transform() 171 MD5STEP(F1, a, b, c, d, in[4] + 0xf57c0faf, 7); in MD5Transform() 172 MD5STEP(F1, d, a, b, c, in[5] + 0x4787c62a, 12); in MD5Transform() 173 MD5STEP(F1, c, d, a, b, in[6] + 0xa8304613, 17); in MD5Transform() 174 MD5STEP(F1, b, c, d, a, in[7] + 0xfd469501, 22); in MD5Transform() [all …]
|
/cts/tests/accessibility/src/android/view/accessibility/cts/ |
D | AccessibilityNodeInfo_CollectionInfoTest.java | 32 CollectionInfo c; in testObtain() local 34 c = CollectionInfo.obtain(0, 1, true); in testObtain() 35 assertNotNull(c); in testObtain() 36 assertEquals(0, c.getRowCount()); in testObtain() 37 assertEquals(1, c.getColumnCount()); in testObtain() 38 assertTrue(c.isHierarchical()); in testObtain() 39 assertEquals(CollectionInfo.SELECTION_MODE_NONE, c.getSelectionMode()); in testObtain() 41 c = CollectionInfo.obtain(1, 2, true, CollectionInfo.SELECTION_MODE_MULTIPLE); in testObtain() 42 assertNotNull(c); in testObtain() 43 assertEquals(1, c.getRowCount()); in testObtain() [all …]
|
/cts/tests/tests/database/src/android/database/sqlite/cts/ |
D | DatabaseStatementTest.java | 86 Cursor c = mDatabase.query("test", null, null, null, null, null, null); in testExecuteStatement() local 87 assertEquals(0, c.getCount()); in testExecuteStatement() 88 c.deactivate(); in testExecuteStatement() 140 Cursor c = mDatabase.query("test", null, null, null, null, null, null); in testStatementLongBinding() local 141 int numCol = c.getColumnIndexOrThrow("num"); in testStatementLongBinding() 142 c.moveToFirst(); in testStatementLongBinding() 144 long num = c.getLong(numCol); in testStatementLongBinding() 146 c.moveToNext(); in testStatementLongBinding() 148 c.close(); in testStatementLongBinding() 162 Cursor c = mDatabase.query("test", null, null, null, null, null, null); in testStatementStringBinding() local [all …]
|
/cts/tests/tests/keystore/src/android/keystore/cts/ |
D | HexEncoding.java | 82 private static int getHexadecimalDigitValue(char c) { in getHexadecimalDigitValue() argument 83 if ((c >= 'a') && (c <= 'f')) { in getHexadecimalDigitValue() 84 return (c - 'a') + 0x0a; in getHexadecimalDigitValue() 85 } else if ((c >= 'A') && (c <= 'F')) { in getHexadecimalDigitValue() 86 return (c - 'A') + 0x0a; in getHexadecimalDigitValue() 87 } else if ((c >= '0') && (c <= '9')) { in getHexadecimalDigitValue() 88 return c - '0'; in getHexadecimalDigitValue() 91 "Invalid hexadecimal digit at position : '" + c + "' (0x" + Integer.toHexString(c) + ")"); in getHexadecimalDigitValue()
|
/cts/tests/tests/util/src/android/util/cts/ |
D | TimeUtilsTest.java | 46 Calendar c = Calendar.getInstance(tz); in testUnitedStates() local 49 c.set(2016, Calendar.OCTOBER, 20, 12, 0, 0); in testUnitedStates() 50 guess = guessTimeZone(c, "us"); in testUnitedStates() 53 c.set(2017, Calendar.JANUARY, 20, 12, 0, 0); in testUnitedStates() 54 guess = guessTimeZone(c, "us"); in testUnitedStates() 68 Calendar c = Calendar.getInstance(tz); in testWeirdUnitedStates() local 71 c.set(2016, Calendar.OCTOBER, 20, 12, 0, 0); in testWeirdUnitedStates() 72 guess = guessTimeZone(c, "us"); in testWeirdUnitedStates() 85 Calendar c = Calendar.getInstance(tz); in testOld() local 88 c.set(2005, Calendar.OCTOBER, 20, 12, 0, 0); in testOld() [all …]
|
/cts/tests/tests/provider/src/android/provider/cts/contacts/ |
D | ContactsContract_DirectoryTest.java | 65 private static String getString(Cursor c, String column) { in getString() argument 66 return c.getString(c.getColumnIndex(column)); in getString() 76 try (Cursor c = getContext().getContentResolver().query(Directory.CONTENT_URI, in waitForDirectorySetup() argument 80 if (c.getCount() == 0) { in waitForDirectorySetup() 84 assertTrue(c.moveToPosition(0)); in waitForDirectorySetup() 85 assertEquals(getContext().getPackageName(), getString(c, Directory.PACKAGE_NAME)); in waitForDirectorySetup() 87 getString(c, Directory.DIRECTORY_AUTHORITY)); in waitForDirectorySetup() 88 assertEquals(DummyGalProvider.DISPLAY_NAME, getString(c, Directory.DISPLAY_NAME)); in waitForDirectorySetup() 89 assertEquals(DummyGalProvider.ACCOUNT_NAME, getString(c, Directory.ACCOUNT_NAME)); in waitForDirectorySetup() 90 assertEquals(DummyGalProvider.ACCOUNT_TYPE, getString(c, Directory.ACCOUNT_TYPE)); in waitForDirectorySetup() [all …]
|
/cts/tests/tests/telecom/src/android/telecom/cts/ |
D | MockConference.java | 55 for (Connection c : getConnections()) { in onDisconnect() 56 c.setDisconnected(new DisconnectCause(DisconnectCause.REMOTE)); in onDisconnect() 57 c.destroy(); in onDisconnect() 80 for (Connection c : getConnections()) { in onMerge() 81 c.setCallerDisplayName( in onMerge() 93 for (Connection c : getConnections()) { in onSwap() 94 c.setCallerDisplayName( in onSwap() 105 for (Connection c : getConnections()) { in onHold() 106 c.setOnHold(); in onHold() 117 for (Connection c : getConnections()) { in onUnhold() [all …]
|
/cts/tests/tests/shortcutmanager/src/android/content/pm/cts/shortcutmanager/ |
D | ShortcutManagerLauncherCallbackTest.java | 134 final MyCallback c = new MyCallback(); in testRegisterAndUnRegister() local 136 getLauncherApps().registerCallback(c, handler); in testRegisterAndUnRegister() 137 getLauncherApps().unregisterCallback(c); in testRegisterAndUnRegister() 141 final MyCallback c = new MyCallback(mPackageContext1.getPackageName()); in testCallbacks() local 152 getLauncherApps().unregisterCallback(c); in testCallbacks() 155 c.reset(); in testCallbacks() 156 getLauncherApps().registerCallback(c, handler); in testCallbacks() 170 retryUntil(() -> c.isCalled(), "callback not called."); in testCallbacks() 171 c.assertCalled(mPackageContext1) in testCallbacks() 183 retryUntil(() -> c.isCalled(), "callback not called."); in testCallbacks() [all …]
|
/cts/libs/vogar-expect/src/vogar/util/ |
D | IoUtils.java | 25 public static void closeQuietly(Closeable c) { in closeQuietly() argument 26 if (c != null) { in closeQuietly() 28 c.close(); in closeQuietly() 34 public static void closeQuietly(Socket c) { in closeQuietly() argument 35 if (c != null) { in closeQuietly() 37 c.close(); in closeQuietly()
|
/cts/libs/json/src/com/android/json/stream/ |
D | JsonReader.java | 663 int c = nextNonWhitespace(); in nextValue() local 664 switch (c) { in nextValue() 676 value = nextString((char) c); in nextValue() 711 int c = buffer[pos++]; in nextNonWhitespace() local 712 switch (c) { in nextNonWhitespace() 721 return c; in nextNonWhitespace() 743 return c; in nextNonWhitespace() 757 return c; in nextNonWhitespace() 777 char c = buffer[pos++]; in skipToEndOfLine() local 778 if (c == '\r' || c == '\n') { in skipToEndOfLine() [all …]
|
/cts/tests/tests/content/src/android/content/cts/ |
D | ClipDescriptionTest.java | 68 Calendar c = Calendar.getInstance(); in logTime() local 70 c.setTimeInMillis(millis); in logTime() 71 return String.format("%tm-%td-%ty %tH:%tM:%tS.%tL", c, c, c, c, c, c, c); in logTime()
|
/cts/tests/camera/src/android/hardware/camera2/cts/ |
D | ExtendedCameraCharacteristicsTest.java | 155 for (CameraCharacteristics c : mCharacteristics) { in testAvailableStreamConfigs() 157 c.get(CameraCharacteristics.SCALER_STREAM_CONFIGURATION_MAP); in testAvailableStreamConfigs() 162 int[] actualCapabilities = c.get(CameraCharacteristics.REQUEST_AVAILABLE_CAPABILITIES); in testAvailableStreamConfigs() 188 c, CameraCharacteristics.SENSOR_INFO_ACTIVE_ARRAY_SIZE); in testAvailableStreamConfigs() 190 Integer hwLevel = c.get(CameraCharacteristics.INFO_SUPPORTED_HARDWARE_LEVEL); in testAvailableStreamConfigs() 308 for (CameraCharacteristics c : mCharacteristics) { in testKeys() 315 List<CameraCharacteristics.Key<?>> allKeys = c.getKeys(); in testKeys() 324 mCollector.expectKeyValueNotNull(c, key); in testKeys() 345 …expectKeyAvailable(c, CameraCharacteristics.COLOR_CORRECTION_AVAILABLE_ABERRATION_MODES , OPT … in testKeys() 346 …expectKeyAvailable(c, CameraCharacteristics.CONTROL_AVAILABLE_MODES , OPT … in testKeys() [all …]
|