Home
last modified time | relevance | path

Searched refs:getBytes (Results 1 – 25 of 64) sorted by relevance

123

/cts/tests/tests/telephony/src/android/telephony/cts/
DMmsTest.java246 req.setMessageClass(PduHeaders.MESSAGE_CLASS_PERSONAL_STR.getBytes()); in buildPdu()
269 part.setContentType(ContentType.TEXT_PLAIN.getBytes()); in addTextPart()
271 part.setContentLocation(TEXT_PART_FILENAME.getBytes()); in addTextPart()
275 part.setContentId(contentId.getBytes()); in addTextPart()
276 part.setData(message.getBytes()); in addTextPart()
287 smilPart.setContentId("smil".getBytes()); in addSmilPart()
288 smilPart.setContentLocation("smil.xml".getBytes()); in addSmilPart()
289 smilPart.setContentType(ContentType.APP_SMIL.getBytes()); in addSmilPart()
290 smilPart.setData(smil.getBytes()); in addSmilPart()
/cts/tests/tests/ndef/src/android/ndef/cts/
DNdefTest.java332 new NdefRecord(NdefRecord.TNF_MIME_MEDIA, "text/plain".getBytes(ASCII), null, in testCreateMime()
333 "foo".getBytes()), in testCreateMime()
334 NdefRecord.createMime("text/plain", "foo".getBytes())); in testCreateMime()
379 new NdefRecord(NdefRecord.TNF_EXTERNAL_TYPE, "a.b:c".getBytes(ASCII), null, null), in testCreateExternal()
384 new NdefRecord(NdefRecord.TNF_EXTERNAL_TYPE, "a.b:c!".getBytes(ASCII), null, null), in testCreateExternal()
429 assertEquals("android.com:pkg".getBytes(), r.getType()); in testCreateApplicationRecord()
431 assertEquals("com.foo.bar".getBytes(), r.getPayload()); in testCreateApplicationRecord()
487 "http://www.android.com".getBytes(), null, null).toUri()); in testToUri()
495 "http://www.android.com".getBytes(), null, null)).toByteArray()).toUri()); in testToUri()
511 new NdefRecord(NdefRecord.TNF_ABSOLUTE_URI, "HTTP://www.android.com".getBytes(), in testToUri()
[all …]
/cts/hostsidetests/appsecurity/test-apps/DocumentClient/src/com/android/cts/documentclient/
DDocumentsClientTest.java148 MoreAsserts.assertEquals("fileone".getBytes(), readFully(uri)); in testOpenSimple()
150 writeFully(uri, "replaced!".getBytes()); in testOpenSimple()
152 MoreAsserts.assertEquals("replaced!".getBytes(), readFully(uri)); in testOpenSimple()
176 writeFully(uri, "meow!".getBytes()); in testCreateNew()
207 MoreAsserts.assertEquals("filetwo".getBytes(), readFully(uri)); in testCreateExisting()
252 writeFully(pic, "pic".getBytes()); in testTree()
253 writeFully(dirPic, "dirPic".getBytes()); in testTree()
257 MoreAsserts.assertEquals("filefour".getBytes(), readFully(file4)); in testTree()
260 MoreAsserts.assertEquals("filefour".getBytes(), readFully(file4)); in testTree()
271 MoreAsserts.assertEquals("dirPic".getBytes(), readFully(dirPic)); in testTree()
/cts/apps/CtsVerifier/src/com/android/cts/verifier/nfc/
DNdefPushSenderActivity.java62 .getBytes(Charset.forName("US-ASCII")); in getTestMessage()
64 byte[] payload = "CTS Verifier NDEF Push Tag".getBytes(Charset.forName("US-ASCII")); in getTestMessage()
DLlcpVersionActivity.java64 .getBytes(Charset.forName("US-ASCII")); in getTestMessage()
66 byte[] payload = "CTS Verifier NDEF Push Tag".getBytes(Charset.forName("US-ASCII")); in getTestMessage()
/cts/tools/tradefed-host/tests/src/com/android/cts/tradefed/testtype/
DTestPackageDefTest.java37 return new ByteArrayInputStream("test data for digest".getBytes()); in testGenerateDigest()
/cts/tests/tests/permission/src/android/permission/cts/
DNoSdCardWritePermissionTest.java41 strm.write("Oops!".getBytes()); in testWriteExternalStorage()
/cts/tools/dex-tools/test/dex/reader/util/
DJavaSource.java54 return new ByteArrayInputStream(src.getBytes()); in openInputStream()
DMemoryByteCode.java57 public byte[] getBytes() { in getBytes() method in MemoryByteCode
/cts/tools/tradefed-host/src/com/android/cts/tradefed/result/
DResultReporter.java49 byte[] data = IssueReporter.getBytes(input, RESULT_XML_BYTES); in reportResult()
DIssueReporter.java101 mCurrentIssue.mBugReport = getBytes(input, BUGREPORT_SIZE); in setBugReport()
118 static byte[] getBytes(InputStream input, int size) throws IOException { in getBytes() method in IssueReporter
/cts/apps/CtsVerifier/src/com/android/cts/verifier/nfc/tech/
DNdefTagTester.java100 byte[] mimeBytes = MIME_TYPE.getBytes(Charset.forName("US-ASCII"));
103 byte[] payload = PAYLOAD.getBytes(Charset.forName("US-ASCII"));
/cts/hostsidetests/appsecurity/test-apps/DocumentProvider/src/com/android/cts/documentprovider/
DMyDocumentsProvider.java113 file1.contents = "fileone".getBytes(); in resetRoots()
121 file2.contents = "filetwo".getBytes(); in resetRoots()
132 file3.contents = "filethree".getBytes(); in resetRoots()
142 file4.contents = "filefour".getBytes(); in resetRoots()
/cts/tests/tests/content/src/android/content/res/cts/
DAssetManager_AssetInputStreamTest.java56 final byte[] bytes = CONTENT_STRING.getBytes(); in testMarkReset()
69 final byte[] bytes = CONTENT_STRING.getBytes(); in testReadMethods()
/cts/tests/tests/bluetooth/src/android/bluetooth/cts/
DScanResultTest.java57 TestUtils.assertArrayEquals(SCAN_RECORD, resultFromParcel.getScanRecord().getBytes()); in testScanResultParceling()
/cts/tests/tests/util/src/android/util/cts/
DXmlEncodingTest.java76 Xml.parse(new ByteArrayInputStream(sourceStr.getBytes(STR_US_ASCII)), in testValueOf()
108 Xml.parse(new ByteArrayInputStream(sourceStr.getBytes(STR_UTF_8)), in testValueOf()
140 Xml.parse(new ByteArrayInputStream(sourceStr.getBytes(STR_UTF_16)), in testValueOf()
172 Xml.parse(new ByteArrayInputStream(sourceStr.getBytes(STR_ISO_8859_1)), in testValueOf()
/cts/libs/testserver/src/android/webkit/cts/
DTestWebServer.java213 return setResponseInternal(requestPath, "".getBytes(), null, null, in setResponseWithNotFoundStatus()
231 return setResponseInternal(requestPath, responseString.getBytes(), responseHeaders, null, in setResponse()
254 requestPath, responseString.getBytes(), responseHeaders, responseAction, in setResponseWithRunnableAction()
271 return setResponseInternal(requestPath, targetPath.getBytes(), responseHeaders, null, in setRedirect()
473 ByteArrayEntity entity = createEntity(buf.toString().getBytes()); in createResponse()
/cts/tests/tests/media/src/android/media/cts/
DClearKeySystemTest.java150 String id = new String(keyIds.get(i).getBytes(Charset.forName("UTF-8"))); in createJsonWebKeySet()
151 String key = new String(keys.get(i).getBytes(Charset.forName("UTF-8"))); in createJsonWebKeySet()
199 byte[] jsonResponse = jwkSet.getBytes(Charset.forName("UTF-8")); in getKeys()
DMediaDrmMockTest.java906 … assertTrue(Arrays.equals(keyStatus.getKeyId(), "key1".getBytes())); in testKeyStatusChange()
909 … assertTrue(Arrays.equals(keyStatus.getKeyId(), "key2".getBytes())); in testKeyStatusChange()
912 … assertTrue(Arrays.equals(keyStatus.getKeyId(), "key3".getBytes())); in testKeyStatusChange()
915 … assertTrue(Arrays.equals(keyStatus.getKeyId(), "key4".getBytes())); in testKeyStatusChange()
918 … assertTrue(Arrays.equals(keyStatus.getKeyId(), "key5".getBytes())); in testKeyStatusChange()
/cts/hostsidetests/devicepolicy/app/DeviceAndProfileOwner/src/com/android/cts/deviceandprofileowner/
DDelegatedCertInstallerTest.java170 mDpm.uninstallCaCert(ADMIN_RECEIVER_COMPONENT, TEST_CA.getBytes()); in tearDown()
178 byte[] cert = TEST_CA.getBytes(); in testCaCertsOperations()
/cts/tests/tests/security/src/android/security/cts/
DBannedFilesTest.java82 byte[] badPattern = "enable_root".getBytes("US-ASCII"); in testNoEnableRoot()
/cts/common/host-side/xml-plan-generator/tests/src/com/android/compatibility/common/xmlgenerator/
DXmlPlanGeneratorTest.java123 final ByteArrayInputStream in = new ByteArrayInputStream(input.getBytes()); in runTestListParser()
/cts/tests/tests/admin/src/android/admin/cts/
DDevicePolicyManagerTest.java724 TEST_CA_STRING1.getBytes()); in testInstallCaCert_failIfNotProfileOwner()
738 mDevicePolicyManager.installCaCert(null, TEST_CA_STRING1.getBytes()); in testInstallCaCert_failIfNotCertInstaller()
751 TEST_CA_STRING1.getBytes()); in testUninstallCaCert_failIfNotProfileOwner()
765 mDevicePolicyManager.uninstallCaCert(null, TEST_CA_STRING1.getBytes()); in testUninstallCaCert_failIfNotCertInstaller()
804 TEST_CA_STRING1.getBytes()); in testHasCaCertInstalled_failIfNotProfileOwner()
818 mDevicePolicyManager.hasCaCertInstalled(null, TEST_CA_STRING1.getBytes()); in testHasCaCertInstalled_failIfNotCertInstaller()
/cts/apps/CtsVerifier/src/com/android/cts/verifier/sample/
DSampleTestActivity.java106 outputStream.write(TEST_STRING.getBytes()); in createFileAndShare()
/cts/apps/CtsVerifier/src/com/android/cts/verifier/
DReportExporter.java60 contents = report.getContents().getBytes(); in doInBackground()

123