/cts/tests/tests/text/src/android/text/cts/ |
D | HtmlTest.java | 110 Spanned s = Html.fromHtml("<font color=\"#00FF00\">something</font>"); in testColor() local 111 ForegroundColorSpan[] colors = s.getSpans(0, s.length(), type); in testColor() 114 s = Html.fromHtml("<font color=\"navy\">NAVY</font>"); in testColor() 115 colors = s.getSpans(0, s.length(), type); in testColor() 118 s = Html.fromHtml("<font color=\"gibberish\">something</font>"); in testColor() 119 colors = s.getSpans(0, s.length(), type); in testColor() 123 s = Html.fromHtml("<font color=\"green\">GREEN</font>"); in testColor() 124 colors = s.getSpans(0, s.length(), type); in testColor() 127 s = Html.fromHtml("<font color=\"gray\">GRAY</font>"); in testColor() 128 colors = s.getSpans(0, s.length(), type); in testColor() [all …]
|
/cts/tests/tests/slice/src/android/slice/cts/ |
D | SliceBuilderTest.java | 51 Slice s = new Slice.Builder(BASE_URI, SPEC) in testInt() local 54 assertEquals(BASE_URI, s.getUri()); in testInt() 55 assertEquals(1, s.getItems().size()); in testInt() 57 SliceItem item = s.getItems().get(0); in testInt() 63 verifySlice(s); in testInt() 69 Slice s = new Slice.Builder(BASE_URI, SPEC) in testIcon() local 72 assertEquals(BASE_URI, s.getUri()); in testIcon() 73 assertEquals(1, s.getItems().size()); in testIcon() 75 SliceItem item = s.getItems().get(0); in testIcon() 81 verifySlice(s); in testIcon() [all …]
|
D | SliceBindingTest.java | 73 Slice s = mSliceManager.bindSlice(BASE_URI, in testSliceUri() local 75 assertEquals(BASE_URI, s.getUri()); in testSliceUri() 81 Slice s = mSliceManager.bindSlice(uri, Collections.emptySet()); in testSubSlice() local 82 assertEquals(uri, s.getUri()); in testSubSlice() 83 assertEquals(1, s.getItems().size()); in testSubSlice() 85 SliceItem item = s.getItems().get(0); in testSubSlice() 96 Slice s = mSliceManager.bindSlice(uri, in testText() local 98 assertEquals(uri, s.getUri()); in testText() 99 assertEquals(1, s.getItems().size()); in testText() 101 SliceItem item = s.getItems().get(0); in testText() [all …]
|
/cts/apps/CameraITS/tools/ |
D | load_scene.py | 27 for s in sys.argv[1:]: 28 if s[:6] == 'scene=' and len(s) > 6: 29 scene = s[6:] 30 elif s[:7] == 'screen=' and len(s) > 7: 31 screen_id = s[7:] 32 elif s[:5] == 'dist=' and len(s) > 5: 33 chart_distance = float(re.sub('cm', '', s[5:])) 34 elif s[:4] == 'fov=' and len(s) > 4: 35 camera_fov = float(s[4:])
|
D | validate_scene.py | 30 for s in sys.argv[1:]: 31 if s[:7] == "camera=" and len(s) > 7: 32 camera_id = s[7:] 33 elif s[:4] == "out=" and len(s) > 4: 34 out_path = s[4:] 35 elif s[:6] == "scene=" and len(s) > 6: 36 scene_desc = s[6:] 37 elif s[:5] == "doAF=" and len(s) > 5: 38 do_af = s[5:] == "True"
|
D | run_sensor_fusion_box.py | 69 for s in sys.argv[1:]: 70 if s[:7] == 'camera=' and len(s) > 7: 71 camera_id = s[7:] 72 if s[:4] == 'fps=' and len(s) > 4: 73 fps = s[4:] 74 elif s[:9] == 'img_size=' and len(s) > 9: 75 img_size = s[9:] 76 elif s[:9] == 'num_runs=' and len(s) > 9: 77 num_runs = int(s[9:]) 78 elif s[:8] == 'rotator=' and len(s) > 8: [all …]
|
D | run_parallel_tests.py | 43 for s in sys.argv[1:]: 44 if s[:8] == "device0=" and len(s) > 8: 45 device0_id = s[8:] 46 elif s[:8] == "device1=" and len(s) > 8: 47 device1_id = s[8:] 48 elif s[:7] == "scenes=" and len(s) > 7: 49 scenes = s[7:].split(',') 50 elif s[:6] == 'chart=' and len(s) > 6: 51 chart_host_id = s[6:]
|
D | run_all_tests.py | 181 for s in sys.argv[1:]: 182 if s[:7] == "camera=" and len(s) > 7: 183 camera_ids = s[7:].split(',') 184 elif s[:7] == "scenes=" and len(s) > 7: 185 scenes = s[7:].split(',') 186 elif s[:6] == 'chart=' and len(s) > 6: 187 chart_host_id = s[6:] 188 elif s[:7] == 'result=' and len(s) > 7: 189 result_device_id = s[7:] 190 elif s[:8] == 'rot_rig=' and len(s) > 8: [all …]
|
/cts/tests/tests/renderscript/src/android/renderscript/cts/ |
D | SingleSourceAllocationTest.java | 30 private ScriptC_single_source_alloc s; field in SingleSourceAllocationTest 40 s = new ScriptC_single_source_alloc(mRS); in setUp() 41 s.set_gDimX(dimX); in setUp() 42 s.set_gDimY(dimY); in setUp() 43 s.set_gDimZ(dimZ); in setUp() 44 s.set_gStart(start); in setUp() 49 s.destroy(); in tearDown() 54 s.invoke_TestElementCreation(); in testElementCreation() 60 s.invoke_TestTypeCreation(); in testTypeCreation() 66 s.invoke_TestAllocationCreationWithUsage(); in testAllocationCreationWithUsage() [all …]
|
D | RsAllocationCopyTest.java | 45 ScriptC_rsallocationcopy s = new ScriptC_rsallocationcopy(mRS); in test_RsAllocationCopy1D_Byte() local 46 s.set_aIn1D(aIn); in test_RsAllocationCopy1D_Byte() 47 s.set_aOut1D(aOut); in test_RsAllocationCopy1D_Byte() 48 s.set_xOff(offset); in test_RsAllocationCopy1D_Byte() 49 s.set_xCount(count); in test_RsAllocationCopy1D_Byte() 50 s.invoke_test1D(); in test_RsAllocationCopy1D_Byte() 92 ScriptC_rsallocationcopy s = new ScriptC_rsallocationcopy(mRS); in test_RsAllocationCopy1D_Short() local 93 s.set_aIn1D(aIn); in test_RsAllocationCopy1D_Short() 94 s.set_aOut1D(aOut); in test_RsAllocationCopy1D_Short() 95 s.set_xOff(offset); in test_RsAllocationCopy1D_Short() [all …]
|
D | struct_pad.rs | 7 } s; 11 _RS_ASSERT(s.i == 7); 12 _RS_ASSERT(s.f4.x == 1.0f); 13 _RS_ASSERT(s.f4.y == 2.0f); 14 _RS_ASSERT(s.f4.z == 3.0f); 15 _RS_ASSERT(s.f4.w == 4.0f); 16 _RS_ASSERT(s.j == 9);
|
D | SingleSourceForEachTest.java | 38 private ScriptC_single_source_script s; field in SingleSourceForEachTest 56 s = new ScriptC_single_source_script(mRS); in setUp() 73 s.destroy(); in tearDown() 78 s.forEach_foo(testInputAlloc, baselineOutputAlloc); in testSingleInputKernelLaunch() 79 s.invoke_testSingleInput(testInputAlloc, testOutputAlloc); in testSingleInputKernelLaunch() 86 s.forEach_goo(testInputAlloc, testInputAlloc2, in testMultiInputKernelLaunch() 88 s.invoke_testMultiInput(testInputAlloc, testInputAlloc2, in testMultiInputKernelLaunch() 105 s.forEach_foo(testInputAlloc, baselineOutputAlloc, sc); in testKernelLaunchWithOptions() 106 s.invoke_testLaunchOptions(testInputAlloc, testOutputAlloc, X, Y); in testKernelLaunchWithOptions() 119 s.set_gAllocOut(baselineOutputAlloc); in testAllocationlessKernelLaunch() [all …]
|
/cts/tests/tests/rscpp/librscpptest/ |
D | rs_jni_allocation.cpp | 434 for (int s = 8; s <= elemsToTest; s += 2) { in Java_android_cts_rscpp_RSAllocationTest_test1DCopy() local 435 passed &= helperCopy1D<float>(rs, s, 0, s, false, RS_TYPE_FLOAT_32); in Java_android_cts_rscpp_RSAllocationTest_test1DCopy() 436 passed &= helperCopy1D<char>(rs, s, 0, s, false, RS_TYPE_SIGNED_8); in Java_android_cts_rscpp_RSAllocationTest_test1DCopy() 437 passed &= helperCopy1D<short>(rs, s, 0, s, false, RS_TYPE_SIGNED_16); in Java_android_cts_rscpp_RSAllocationTest_test1DCopy() 438 passed &= helperCopy1D<int>(rs, s, 0, s, false, RS_TYPE_SIGNED_32); in Java_android_cts_rscpp_RSAllocationTest_test1DCopy() 439 passed &= helperCopy1D<double>(rs, s, 0, s, false, RS_TYPE_FLOAT_64); in Java_android_cts_rscpp_RSAllocationTest_test1DCopy() 442 for (int off = 0; off < s; off ++) { in Java_android_cts_rscpp_RSAllocationTest_test1DCopy() 443 for (int count = 1; count <= s - off; count ++) { in Java_android_cts_rscpp_RSAllocationTest_test1DCopy() 444 passed &= helperCopy1D<float>(rs, s, off, count, true, RS_TYPE_FLOAT_32); in Java_android_cts_rscpp_RSAllocationTest_test1DCopy() 445 passed &= helperCopy1D<char>(rs, s, off, count, true, RS_TYPE_SIGNED_8); in Java_android_cts_rscpp_RSAllocationTest_test1DCopy() [all …]
|
/cts/tests/tests/content/src/android/content/cts/ |
D | SearchRecentSuggestionsProviderTest.java | 46 final MockSRSProvider s = new MockSRSProvider(); in testSearchRecentSuggestionsProvider() local 49 assertFalse(s.isOnCreateCalled()); in testSearchRecentSuggestionsProvider() 50 s.attachInfo(mProviderContext, null); in testSearchRecentSuggestionsProvider() 51 assertTrue(s.isOnCreateCalled()); in testSearchRecentSuggestionsProvider() 53 assertNotNull(s.getType(TEST_URI)); in testSearchRecentSuggestionsProvider() 59 Cursor c = s.query(contentUri, null, null, selArgs, null); in testSearchRecentSuggestionsProvider() 62 s.insert(TEST_URI, new ContentValues()); in testSearchRecentSuggestionsProvider() 63 c = s.query(contentUri, null, null, selArgs, null); in testSearchRecentSuggestionsProvider() 66 s.insert(TEST_URI, new ContentValues()); in testSearchRecentSuggestionsProvider() 67 c = s.query(contentUri, null, null, selArgs, null); in testSearchRecentSuggestionsProvider() [all …]
|
/cts/hostsidetests/security/securityPatch/CVE-2014-3145/ |
D | poc.c | 63 static int send_receive_packet(int s[2], const void* pkt, int len) in send_receive_packet() 68 ret = send(s[1], pkt, len, 0); in send_receive_packet() 73 ret = recv(s[0], tmp, len, MSG_DONTWAIT); in send_receive_packet() 93 int s[2], ret; in main() local 95 ret = socketpair(AF_UNIX, SOCK_DGRAM, 0, s); in main() 100 ret = setsockopt(s[0], SOL_SOCKET, SO_ATTACH_FILTER, in main() 106 ret = send_receive_packet(s, &chksz, sizeof(chksz)); in main() 112 ret = setsockopt(s[0], SOL_SOCKET, SO_ATTACH_FILTER, in main() 118 ret = send_receive_packet(s, &chksz, sizeof(chksz)); in main() 124 ret = setsockopt(s[0], SOL_SOCKET, SO_ATTACH_FILTER, in main() [all …]
|
/cts/tests/security/src/android/keystore/cts/ |
D | Attestation.java | 124 StringBuilder s = new StringBuilder(); in toString() local 125 s.append("Attest version: " + attestationVersion); in toString() 126 s.append("\nAttest security: " + securityLevelToString(attestationSecurityLevel)); in toString() 127 s.append("\nKM version: " + keymasterVersion); in toString() 128 s.append("\nKM security: " + securityLevelToString(keymasterSecurityLevel)); in toString() 130 s.append("\nChallenge"); in toString() 133 s.append(": [" + stringChallenge + "]"); in toString() 135 s.append(" (base64): [" + BaseEncoding.base64().encode(attestationChallenge) + "]"); in toString() 138 s.append("\nUnique ID (base64): [" + BaseEncoding.base64().encode(uniqueId) + "]"); in toString() 141 s.append("\n-- SW enforced --"); in toString() [all …]
|
/cts/apps/CameraITS/tests/scene1/ |
D | test_latching.py | 39 e, s = its.target.get_target_exposure_combos(cam)["midExposureTime"] 47 its.objects.manual_capture_request(s, e, 0.0, True, props), 48 its.objects.manual_capture_request(s, e, 0.0, True, props), 49 its.objects.manual_capture_request(s*2,e, 0.0, True, props), 50 its.objects.manual_capture_request(s*2,e, 0.0, True, props), 51 its.objects.manual_capture_request(s, e, 0.0, True, props), 52 its.objects.manual_capture_request(s, e, 0.0, True, props), 53 its.objects.manual_capture_request(s, e*2, 0.0, True, props), 54 its.objects.manual_capture_request(s, e, 0.0, True, props), 55 its.objects.manual_capture_request(s*2,e, 0.0, True, props), [all …]
|
/cts/tests/tests/net/src/android/net/ipv6/cts/ |
D | PingTest.java | 90 FileDescriptor s = Os.socket(AF_INET6, SOCK_DGRAM, IPPROTO_ICMPV6); in createPingSocket() local 91 Os.setsockoptTimeval(s, SOL_SOCKET, SO_RCVTIMEO, StructTimeval.fromMillis(100)); in createPingSocket() 92 return s; in createPingSocket() 98 private void sendPing(FileDescriptor s, in sendPing() argument 104 int ret = Os.sendto(s, ByteBuffer.wrap(packet), 0, address, port); in sendPing() 111 private void checkResponse(FileDescriptor s, InetAddress dest, in checkResponse() argument 119 bytesRead = Os.recvfrom(s, responseBuffer, 0, from); in checkResponse() 128 bytesRead = Os.read(s, responseBuffer); in checkResponse() 141 int id = ((InetSocketAddress) Os.getsockname(s)).getPort(); in checkResponse() 162 FileDescriptor s = createPingSocket(); in testLoopbackPing() local [all …]
|
/cts/common/device-side/util/jni/ |
D | android_cts_FileUtils.cpp | 53 struct stat s; in android_cts_FileUtils_getFileStatus() local 55 int res = statLinks == true ? lstat(pathStr, &s) : stat(pathStr, &s); in android_cts_FileUtils_getFileStatus() 60 env->SetIntField(fileStatus, gFileStatusDevFieldID, s.st_dev); in android_cts_FileUtils_getFileStatus() 61 env->SetIntField(fileStatus, gFileStatusInoFieldID, s.st_ino); in android_cts_FileUtils_getFileStatus() 62 env->SetIntField(fileStatus, gFileStatusModeFieldID, s.st_mode); in android_cts_FileUtils_getFileStatus() 63 env->SetIntField(fileStatus, gFileStatusNlinkFieldID, s.st_nlink); in android_cts_FileUtils_getFileStatus() 64 env->SetIntField(fileStatus, gFileStatusUidFieldID, s.st_uid); in android_cts_FileUtils_getFileStatus() 65 env->SetIntField(fileStatus, gFileStatusGidFieldID, s.st_gid); in android_cts_FileUtils_getFileStatus() 66 env->SetLongField(fileStatus, gFileStatusSizeFieldID, s.st_size); in android_cts_FileUtils_getFileStatus() 67 env->SetIntField(fileStatus, gFileStatusBlksizeFieldID, s.st_blksize); in android_cts_FileUtils_getFileStatus() [all …]
|
/cts/apps/CameraITS/pymodules/its/ |
D | objects.py | 184 out_sizes = [s for s in out_sizes if 185 s[0] <= max_size[0] and s[1] <= max_size[1]] 188 out_sizes = [s for s in out_sizes if 189 abs(ar - s[0] / float(s[1])) <= AR_TOLERANCE] 190 out_sizes.sort(reverse=True, key=lambda s: s[0]) # 1st pass, sort by width 191 out_sizes.sort(reverse=True, key=lambda s: s[0]*s[1]) # sort by area 264 s = min(props['android.sensor.info.sensitivityRange']) 266 req = manual_capture_request(s,e)
|
/cts/tests/sensor/src/android/hardware/cts/ |
D | SensorAdditionalInfoTest.java | 54 for (Sensor s : list) { in testSensorAdditionalInfo() 57 if (s.getType() >= Sensor.TYPE_DEVICE_PRIVATE_BASE || in testSensorAdditionalInfo() 58 !s.isAdditionalInfoSupported() || in testSensorAdditionalInfo() 59 s.getReportingMode() == Sensor.REPORTING_MODE_ONE_SHOT || in testSensorAdditionalInfo() 60 s.getReportingMode() == Sensor.REPORTING_MODE_ON_CHANGE) { in testSensorAdditionalInfo() 64 runSensorAdditionalInfoTest(s); in testSensorAdditionalInfo() 66 errors.add("Sensor: " + s.getName() + ", error: " + e.getMessage()); in testSensorAdditionalInfo() 81 private void runSensorAdditionalInfoTest(Sensor s) throws AssertionError { in runSensorAdditionalInfoTest() argument 84 AdditionalInfoVerifier verifier = new AdditionalInfoVerifier(s); in runSensorAdditionalInfoTest() 87 assertTrue(String.format("Register sensor listener for %s failed.", s.getName()), in runSensorAdditionalInfoTest() [all …]
|
/cts/tests/tests/animation/src/android/animation/cts/ |
D | ShapeHolder.java | 94 Shape s = mShape.getShape(); in setWidth() local 95 s.resize(width, s.getHeight()); in setWidth() 103 Shape s = mShape.getShape(); in setHeight() local 104 s.resize(s.getWidth(), height); in setHeight() 107 public ShapeHolder(ShapeDrawable s) { in ShapeHolder() argument 108 mShape = s; in ShapeHolder()
|
/cts/hostsidetests/incident/src/com/android/server/cts/ |
D | BatteryStatsIncidentTest.java | 109 private static void testSystemProto(SystemProto s) throws Exception { in testSystemProto() argument 111 assertNotNull(s); in testSystemProto() 113 SystemProto.Battery b = s.getBattery(); in testSystemProto() 142 SystemProto.BatteryDischarge bd = s.getBatteryDischarge(); in testSystemProto() 165 assertTrue(-1 <= s.getChargeTimeRemainingMs()); in testSystemProto() 166 assertTrue(-1 <= s.getDischargeTimeRemainingMs()); in testSystemProto() 168 for (SystemProto.BatteryLevelStep bls : s.getChargeStepList()) { in testSystemProto() 171 for (SystemProto.BatteryLevelStep bls : s.getDischargeStepList()) { in testSystemProto() 175 for (SystemProto.DataConnection dc : s.getDataConnectionList()) { in testSystemProto() 184 testControllerActivityProto(s.getGlobalBluetoothController()); in testSystemProto() [all …]
|
/cts/apps/CameraITS/tests/dng_noise_model/ |
D | dng_noise_model.py | 117 s = sens_min 122 while s <= sens_max + 1: 123 print "ISO %d" % round(s) 126 plt_s.set_title("ISO %d" % round(s)) 133 e = int(math.pow(2, b)*auto_e/float(s)) 134 req = its.objects.manual_capture_request(round(s), e, f_dist) 176 measured_models[pidx].append([round(s), S, O]) 177 print "Sensitivity %d: %e*y + %e (R=%f)" % (round(s), S, O, R) 180 samples[pidx].extend([(round(s), mean, var) for (mean, var) in samples_s[pidx]]) 191 fig.savefig("%s_samples_iso%04d.png" % (NAME, round(s))) [all …]
|
/cts/apps/CtsVerifier/src/com/android/cts/verifier/nfc/hce/ |
D | HceUtils.java | 53 public static byte[] hexStringToBytes(String s) { in hexStringToBytes() argument 54 if (s == null || s.length() == 0) return null; in hexStringToBytes() 55 int len = s.length(); in hexStringToBytes() 57 s = '0' + s; in hexStringToBytes() 62 data[i / 2] = (byte) ((Character.digit(s.charAt(i), 16) << 4) in hexStringToBytes() 63 + Character.digit(s.charAt(i+1), 16)); in hexStringToBytes()
|