calabash-android 0.4.7.pre3 → 0.4.7.pre4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/calabash-android/lib/TestServer.apk +0 -0
- data/lib/calabash-android/version.rb +1 -1
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/actions/HttpServer.java +8 -1
- data/test-server/instrumentation-backend/src/sh/calaba/instrumentationbackend/query/ast/UIQueryUtils.java +10 -3
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 38ea0a7d4c70d2f1e51351ce4cd390af26710880
|
4
|
+
data.tar.gz: 715c679a7e4cd6dc255ca1f5028c11b60f808151
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1ae14e2aec7bb5685c387a5a48ab73eadb0f86ac1d2c64b95bcba962bc5037720585b2cec0538958d0799be4cd6303422a4f72fb2f999c7955d2f8817ce0182a
|
7
|
+
data.tar.gz: 40b134d72e179604291e76e15274cc81966cb03c95b1f1d8a4f99a71c15d6a83668425baa147f060665717f31a913579d0dcefa435be6aa755925d33de913b68
|
Binary file
|
@@ -93,7 +93,14 @@ public class HttpServer extends NanoHTTPD {
|
|
93
93
|
return new NanoHTTPD.Response(HTTP_OK, "application/json;charset=utf-8", JSONUtils.asJson(dumpTree));
|
94
94
|
}
|
95
95
|
Map<?,?> dumpTree = new ViewDump().dumpPathWithoutElements(path);
|
96
|
-
|
96
|
+
if (dumpTree == null) {
|
97
|
+
return new NanoHTTPD.Response(HTTP_NOTFOUND, "application/json;charset=utf-8", "{}");
|
98
|
+
}
|
99
|
+
else {
|
100
|
+
return new NanoHTTPD.Response(HTTP_OK, "application/json;charset=utf-8", JSONUtils.asJson(dumpTree));
|
101
|
+
}
|
102
|
+
|
103
|
+
|
97
104
|
}
|
98
105
|
|
99
106
|
|
@@ -297,6 +297,7 @@ public class UIQueryUtils {
|
|
297
297
|
|
298
298
|
@SuppressWarnings({ "unchecked", "rawtypes" })
|
299
299
|
public static Map<?,?> mapWithElAsNull(Map<?,?> dump) {
|
300
|
+
if (dump == null) return null;
|
300
301
|
HashMap result = new HashMap(dump);
|
301
302
|
result.put("el",null);
|
302
303
|
return result;
|
@@ -330,9 +331,15 @@ public class UIQueryUtils {
|
|
330
331
|
List<View> currentChildren = dummyQuery.rootViews();
|
331
332
|
|
332
333
|
for (Integer i:path) {
|
333
|
-
|
334
|
-
|
335
|
-
|
334
|
+
if (i < currentChildren.size()) {
|
335
|
+
View child = currentChildren.get(i);
|
336
|
+
currentView = serializeViewToDump(child);
|
337
|
+
currentChildren = UIQueryUtils.subviews(child);
|
338
|
+
}
|
339
|
+
else {
|
340
|
+
return null;
|
341
|
+
}
|
342
|
+
|
336
343
|
}
|
337
344
|
|
338
345
|
return currentView;
|