selendroid 0.1.3 → 0.1.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3a30f916590d0dc0a370b9532e7570eb3fc26f85
|
4
|
+
data.tar.gz: 1ef8af24a20196affe81e0f6a60536696e26bc97
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 22d113be0666df63a39c527933c0e21e5e94abcf49508b42fb42718e73b6a72088541bcab547c3a3088b73b5a1b59907c5993a711f06c7a314f48e90aa9bdcb5
|
7
|
+
data.tar.gz: 0026759a5030aeea2e1237d813489e60bf478b2267222481a310cc97ac0c70a48dda142a36431b3f19076d4adcb1e77fb564f1801d97611224ee6072b710303d
|
data/bin/selendroid
CHANGED
@@ -21,8 +21,10 @@ def print_comamndline_help
|
|
21
21
|
Builds the selendroid-server for the given apk.
|
22
22
|
console
|
23
23
|
Starts the selendroid-server on the device (apps must be already installed) and opens an irb console with an active WebDriver session.
|
24
|
-
The selendroid-inspector web app is running on: http://localhost:8080/inspector
|
25
|
-
|
24
|
+
The selendroid-inspector web app is running on: http://localhost:8080/inspector
|
25
|
+
version
|
26
|
+
prints the gem version
|
27
|
+
To find help, please visit the official selendroid wiki: http://goo.gl/z30pj
|
26
28
|
EOF
|
27
29
|
end
|
28
30
|
|
@@ -59,6 +61,9 @@ elsif cmd == 'build'
|
|
59
61
|
rebuild_selendroid(relative_to_full_path(ARGV.shift))
|
60
62
|
end
|
61
63
|
exit 0
|
64
|
+
elsif cmd == 'version'
|
65
|
+
puts Selendroid::VERSION
|
66
|
+
exit 0
|
62
67
|
else
|
63
68
|
print_comamndline_help
|
64
69
|
exit 0
|
@@ -4,7 +4,8 @@ require 'tempfile'
|
|
4
4
|
|
5
5
|
def rebuild_selendroid(app)
|
6
6
|
aut_base_package = %x[ aapt dump badging '#{app}' | grep package | cut -d '=' -f2-|awk '{ print $1}' | tr -d "'" ]
|
7
|
-
|
7
|
+
aut_base_package = aut_base_package.tr("\n","")
|
8
|
+
puts "Building selendroid-server for package #{aut_base_package.dump}"
|
8
9
|
|
9
10
|
test_server_file_name = selendroid_server_path(aut_base_package)
|
10
11
|
FileUtils.mkdir_p File.dirname(test_server_file_name) unless File.exist? File.dirname(test_server_file_name)
|
@@ -17,7 +18,7 @@ def rebuild_selendroid(app)
|
|
17
18
|
FileUtils.cp(unsigned_test_apk, "TestServer.apk")
|
18
19
|
FileUtils.cp(File.join(File.dirname(__FILE__), '..','..', 'selendroid-prebuild/AndroidManifest.xml'), "AndroidManifest.xml")
|
19
20
|
|
20
|
-
unless system %Q{"#{RbConfig.ruby}" -pi.bak -e "gsub(
|
21
|
+
unless system %Q{"#{RbConfig.ruby}" -pi.bak -e "gsub(/org.openqa.selendroid.testapp/, '#{aut_base_package}')" AndroidManifest.xml}
|
21
22
|
raise "Could not replace package name in manifest"
|
22
23
|
end
|
23
24
|
|
@@ -43,6 +43,17 @@ def get_window_source
|
|
43
43
|
JSON.pretty_generate( $selendroid_driver.page_source)
|
44
44
|
end
|
45
45
|
|
46
|
+
def inspector
|
47
|
+
link = "http://localhost:#{ENV["SELENDROID_SERVER_PORT"]}/inspector"
|
48
|
+
if RbConfig::CONFIG['host_os'] =~ /mswin|mingw|cygwin/ then
|
49
|
+
system("start #{link}")
|
50
|
+
elsif RbConfig::CONFIG['host_os'] =~ /darwin/ then
|
51
|
+
system("open #{link}")
|
52
|
+
elsif RbConfig::CONFIG['host_os'] =~ /linux/ then
|
53
|
+
system("xdg-open #{link}")
|
54
|
+
end
|
55
|
+
end
|
56
|
+
|
46
57
|
def helpme
|
47
58
|
puts "Client-driver is available under: driver".green
|
48
59
|
puts "Official Webdriver Ruby bindins wiki: http://goo.gl/nJ9CJ".green
|
data/lib/selendroid/version.rb
CHANGED
@@ -2,12 +2,10 @@
|
|
2
2
|
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
3
3
|
package="org.openqa.selendroid"
|
4
4
|
android:versionCode="1"
|
5
|
-
android:versionName="0.
|
6
|
-
<uses-sdk android:minSdkVersion="
|
5
|
+
android:versionName="0.2" >
|
6
|
+
<uses-sdk android:minSdkVersion="10" />
|
7
7
|
|
8
|
-
<instrumentation
|
9
|
-
android:name="org.openqa.selendroid.ServerInstrumentation"
|
10
|
-
android:targetPackage="org.openqa.selendroid.testapp" />
|
8
|
+
<instrumentation android:name="org.openqa.selendroid.ServerInstrumentation" android:targetPackage="org.openqa.selendroid.testapp" />
|
11
9
|
|
12
10
|
<uses-permission android:name="android.permission.INTERNET" />
|
13
11
|
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
|
Binary file
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: selendroid
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Dominik Dary
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2013-
|
11
|
+
date: 2013-03-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rubyzip
|