xamarin-automators-calabash 0.1.0 → 0.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/xamarin-automators-calabash.rb +12 -1
- 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: 3043733165676ca0cd221b3dc405f74009b08d17
|
4
|
+
data.tar.gz: f03186de8b994d30b65227f745616caa52bb66c6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: bf42c0cd78f94491e5f265dafcfe3dfe26ec4012f49e9bf6b4a1dfd6a515239841220ec067bd23bbc321184d8c23ab7cd0403f2ce314f1ce217edf519c988f03
|
7
|
+
data.tar.gz: 4b8324dd7c6f681a59f560b8b961d7bc2189453b50ae44cad55e369c9b5d23c5028bf2442b1162c80ce026bdda6f4a77d53eb0c69162ce4939bdaaf14d6baf28
|
@@ -2,20 +2,31 @@ require 'awesome_print'
|
|
2
2
|
|
3
3
|
def get_root_indexes
|
4
4
|
all_items = (query "*")
|
5
|
+
all_items.map {|x| x.delete("description")}
|
5
6
|
indexes = Array.new
|
7
|
+
print "Found root(s) at: "
|
8
|
+
first = true
|
6
9
|
(0..(all_items).count-1).each do |i|
|
7
10
|
parents_children = query("* index:#{i} parent * index:0 child *")
|
11
|
+
parents_children.map {|x| x.delete("description")}
|
8
12
|
unless parents_children.include? all_items[i]
|
13
|
+
if first
|
14
|
+
print "#{i}"
|
15
|
+
first = false
|
16
|
+
else
|
17
|
+
print ", #{i}"
|
18
|
+
end
|
9
19
|
indexes.push i
|
10
20
|
end
|
11
21
|
end
|
22
|
+
print "\n"
|
12
23
|
return indexes
|
13
24
|
end
|
14
25
|
|
15
26
|
def print_tree(show_class=false)
|
27
|
+
puts "Finding roots..."
|
16
28
|
roots = get_root_indexes
|
17
29
|
@count = roots.count
|
18
|
-
puts "Found roots #{roots.to_s}"
|
19
30
|
roots.each do |i|
|
20
31
|
print_tree_recurse("* index:#{i}", (query "* index:#{i}").first, 0, show_class)
|
21
32
|
end
|