Home
last modified time | relevance | path

Searched refs:json (Results 1 – 25 of 54) sorted by relevance

123

/cts/tools/cts-test-metrics/
DREADME1 The parse_test_metrics.py script can be used to parse test metrics json files. Run the following
3 python parse_test_metrics.py CtsCameraTestCases.reportlog.json
6 python parse_test_metrics.py CtsCameraTestCases.reportlog.json CtsUiHostTestCases.reportlog.json
7 python parse_test_metrics.py *.json
9 Test metrics json files can be found in $CTS_ROOT/repository/results/$RESULT_DIR/report-log-files/
12 The MetricsParser class defines functions to parse a json file. The _Parse function takes a filename
13 as input, reads the json file and adds the json object to json_data. The _PrintJson function
Dparse_test_metrics.py17 import argparse, json, sys
33 json_data = json.load(json_file)
/cts/libs/input/src/com/android/cts/input/
DHidDevice.java25 import org.json.JSONArray;
26 import org.json.JSONException;
27 import org.json.JSONObject;
121 JSONObject json = new JSONObject(); in sendHidReport() local
123 json.put("command", "report"); in sendHidReport()
124 json.put("id", mId); in sendHidReport()
125 json.put("report", new JSONArray(report)); in sendHidReport()
129 writeCommands(json.toString().getBytes()); in sendHidReport()
DUinputDevice.java24 import org.json.JSONArray;
25 import org.json.JSONException;
26 import org.json.JSONObject;
119 JSONObject json = new JSONObject(); in injectEvents() local
121 json.put("command", "inject"); in injectEvents()
122 json.put("id", mId); in injectEvents()
123 json.put("events", new JSONArray(evdevEvents)); in injectEvents()
127 writeCommands(json.toString().getBytes()); in injectEvents()
DInputJsonParser.java30 import org.json.JSONArray;
31 import org.json.JSONException;
32 import org.json.JSONObject;
154 JSONObject json = new JSONObject(readRawResource(resourceId)); in readDeviceId() local
155 return json.getInt("id"); in readDeviceId()
169 JSONObject json = new JSONObject(readRawResource(resourceId)); in readVendorId() local
170 return json.getInt("vid"); in readVendorId()
184 JSONObject json = new JSONObject(readRawResource(resourceId)); in readSources() local
185 return sourceFromString(json.optString("source")); in readSources()
199 JSONObject json = new JSONObject(readRawResource(resourceId)); in readProductId() local
[all …]
DVirtualInputDevice.java32 import org.json.JSONException;
33 import org.json.JSONObject;
162 JSONObject json = new JSONObject(); in delay() local
164 json.put("command", "delay"); in delay()
165 json.put("id", mId); in delay()
166 json.put("duration", milliSeconds); in delay()
171 writeCommands(json.toString().getBytes()); in delay()
/cts/tests/tests/view/src/android/view/cts/input/
DInputDeviceMultiDeviceKeyEventTest.java38 import org.json.JSONArray;
39 import org.json.JSONException;
40 import org.json.JSONObject;
129 JSONObject json = new JSONObject(); in createDeviceRegisterCommand() local
132 json.put("id", deviceId); in createDeviceRegisterCommand()
133 json.put("type", "uinput"); in createDeviceRegisterCommand()
134 json.put("command", "register"); in createDeviceRegisterCommand()
135 json.put("name", "Virtual All Buttons Device (Test)"); in createDeviceRegisterCommand()
136 json.put("vid", GOOGLE_VENDOR_ID); in createDeviceRegisterCommand()
137 json.put("pid", GOOGLE_VIRTUAL_KEYBOARD_ID + deviceId); in createDeviceRegisterCommand()
[all …]
DInputDeviceKeyLayoutMapTest.java37 import org.json.JSONArray;
38 import org.json.JSONException;
39 import org.json.JSONObject;
167 JSONObject json = new JSONObject(); in createDeviceRegisterCommand() local
170 json.put("id", DEVICE_ID); in createDeviceRegisterCommand()
171 json.put("type", "uinput"); in createDeviceRegisterCommand()
172 json.put("command", "register"); in createDeviceRegisterCommand()
173 json.put("name", "Virtual All Buttons Device (Test)"); in createDeviceRegisterCommand()
174 json.put("vid", GOOGLE_VENDOR_ID); in createDeviceRegisterCommand()
175 json.put("pid", GOOGLE_VIRTUAL_KEYBOARD_ID); in createDeviceRegisterCommand()
[all …]
/cts/tests/tests/util/src/android/util/cts/
DJsonReaderTest.java129 String json = "{\n" + in testHelloWorld() local
133 JsonReader reader = new JsonReader(new StringReader(json)); in testHelloWorld()
167 String json = "[\"a\"," in testCharacterUnescaping() local
187 JsonReader reader = new JsonReader(new StringReader(json)); in testCharacterUnescaping()
223 String json = "[-0.0," in testDoubles() local
238 JsonReader reader = new JsonReader(new StringReader(json)); in testDoubles()
260 String json = "[" in testLenientDoubles() local
268 JsonReader reader = new JsonReader(new StringReader(json)); in testLenientDoubles()
295 String json = "[\"" + new String(pad) + "\",33333]"; in testBufferBoundary() local
296 JsonReader reader = new JsonReader(new StringReader(json)); in testBufferBoundary()
[all …]
/cts/tests/camera/utils/src/android/hardware/camera2/cts/helpers/
DCameraMetadataGetter.java53 import org.json.JSONArray;
54 import org.json.JSONObject;
248 private static Object serializeRational(Rational rat) throws org.json.JSONException { in serializeRational()
256 private static Object serializeSize(Size size) throws org.json.JSONException { in serializeSize()
264 private static Object serializeSizeF(SizeF size) throws org.json.JSONException { in serializeSizeF()
272 private static Object serializeRect(Rect rect) throws org.json.JSONException { in serializeRect()
281 private static Object serializePoint(Point point) throws org.json.JSONException { in serializePoint()
290 throws org.json.JSONException { in serializeFace()
304 throws org.json.JSONException { in serializeStreamConfigurationMap()
332 throws org.json.JSONException { in serializeMeteringRectangle()
[all …]
/cts/apps/CtsVerifier/src/com/android/cts/verifier/camera/its/
DItsSerializer.java43 import org.json.JSONArray;
44 import org.json.JSONObject;
73 private static Object serializeRational(Rational rat) throws org.json.JSONException { in serializeRational()
81 private static Object serializeSize(Size size) throws org.json.JSONException { in serializeSize()
89 private static Object serializeSizeF(SizeF size) throws org.json.JSONException { in serializeSizeF()
97 private static Object serializeRect(Rect rect) throws org.json.JSONException { in serializeRect()
106 private static Object serializePoint(Point point) throws org.json.JSONException { in serializePoint()
115 throws org.json.JSONException { in serializeFace()
135 throws org.json.JSONException { in serializeStreamConfigurationMap()
176 throws org.json.JSONException { in serializeMeteringRectangle()
[all …]
/cts/apps/CameraITS/utils/
Dits_session_utils.py19 import json
300 self.sock.send(json.dumps(cmd).encode() + '\n'.encode())
320 self.sock.send(json.dumps(cmd).encode() + '\n'.encode())
340 jobj = json.loads(line)
376 self.sock.send(json.dumps(cmd).encode() + '\n'.encode())
383 self.sock.send(json.dumps(cmd).encode() + '\n'.encode())
396 self.sock.send(json.dumps(cmd).encode() + '\n'.encode())
413 self.sock.send(json.dumps(cmd).encode() + '\n'.encode())
442 self.sock.send(json.dumps(cmd).encode() + '\n'.encode())
745 self.sock.send(json.dumps(cmd).encode() + '\n'.encode())
[all …]
Dtarget_exposure_utils.py17 import json
186 f.write(json.dumps({'exposure': exposure}))
200 o = json.load(f)
/cts/hostsidetests/seccomp/app/
Dgen_blocklist.py16 import json
182 json.dump(allowed, f, sort_keys=True, indent=2)
186 json.dump(blocked, f, sort_keys=True, indent=2)
/cts/libs/json/
DAndroid.bp22 name: "json",
31 static_libs: ["json"],
/cts/libs/vogar-expect/
DAndroid.bp30 "json",
46 "json",
/cts/hostsidetests/edi/src/android/edi/cts/
DDynamicPartitionsDeviceInfo.java25 import org.json.JSONException;
26 import org.json.JSONObject;
/cts/tests/framework/base/windowmanager/src/android/server/wm/intent/
DIntentGenerationTests.java27 import org.json.JSONException;
28 import org.json.JSONObject;
DIntentTests.java34 import org.json.JSONException;
35 import org.json.JSONObject;
/cts/libs/json/src/com/android/json/stream/
DJsonScope.java17 package com.android.json.stream;
DJsonToken.java17 package com.android.json.stream;
DNewlineDelimitedJsonWriter.java17 package com.android.json.stream;
/cts/apps/CameraITS/
D.gitignore3 *.json
/cts/tests/tests/hardware/
DOWNERS7 per-file *.json=svv@google.com
/cts/tools/cts-media/
Dget_achievable_rates.py17 import argparse, json, math, re, sys, zipfile
305 def parse_json(self, json, device, build): argument
306 for test, results in json:
334 jsonData = json.load(jsonFile, encoding='utf-8')
341 jsonData = json.load(jsonFile, encoding='utf-8', object_pairs_hook=lambda items: items)

123