xamarin-test-cloud 2.0.0.pre2 → 2.0.0.pre4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +1 -1
- data/lib/xamarin-test-cloud/cli.rb +81 -11
- data/lib/xamarin-test-cloud/version.rb +1 -1
- metadata +3 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c5abd84d95ae2a746e1d70bb479542db758b27af
|
4
|
+
data.tar.gz: eadbec669fdee84204a4ce744dc9685ff5979795
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: dc8a5c6fab7135a1d7094e2d347068c3c833185df051462c86042a1ffec92129d5a7d2ca8ef1df398fa1f96542c064864dc44ea626c0b5bbc69d94011a299a53
|
7
|
+
data.tar.gz: f5e28ac7df1c1a5dae4a2d7aca10a031d933bf5dc866c9f090ec7161a190f3296143fa1174510db1fa15ad443541569fbae9862f3bdce3ddb26b59c6e3c0860d
|
data/README.md
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
## Test Cloud Command Line
|
2
2
|
|
3
|
-
[![Build Status](https://
|
3
|
+
[![Build Status](https://travis-ci.com/xamarinhq/test-cloud-command-line.svg?token=fsyxqhAht7X7tLURqAAp&branch=master)](https://travis-ci.com/xamarinhq/test-cloud-command-line)
|
4
4
|
|
5
5
|
### Requirements
|
6
6
|
|
@@ -153,7 +153,6 @@ module XamarinTestCloud
|
|
153
153
|
:required => false,
|
154
154
|
:type => :string
|
155
155
|
|
156
|
-
|
157
156
|
def submit(app, api_key)
|
158
157
|
|
159
158
|
self.pretty = options[:pretty]
|
@@ -620,9 +619,59 @@ module XamarinTestCloud
|
|
620
619
|
app.end_with? '.ipa'
|
621
620
|
end
|
622
621
|
|
623
|
-
def
|
622
|
+
def is_calabash_2?
|
623
|
+
detect_calabash_2
|
624
|
+
end
|
625
|
+
|
626
|
+
def get_calabash_version_from_bundler
|
627
|
+
cmd = "bundle exec ruby -e \"begin; require 'calabash/version';puts Calabash::VERSION;rescue LoadError => e; puts '';end\""
|
628
|
+
|
629
|
+
`#{cmd}`.strip
|
630
|
+
end
|
631
|
+
|
632
|
+
def detect_calabash_2
|
633
|
+
@detected_calabash_2 ||= lambda do
|
634
|
+
log "Auto-detecting if Calabash 2.0 testsuite" if debug?
|
635
|
+
|
636
|
+
# Implicitly detect
|
637
|
+
if File.exist?(workspace_gemfile)
|
638
|
+
FileUtils.cd(self.workspace) do
|
639
|
+
version = get_calabash_version_from_bundler
|
640
|
+
|
641
|
+
if version.split('.').first.to_i >= 2
|
642
|
+
log "It is a Calabash 2.0 testsuite" if debug?
|
643
|
+
return true
|
644
|
+
end
|
645
|
+
end
|
646
|
+
end
|
647
|
+
|
648
|
+
false
|
649
|
+
end.call
|
650
|
+
end
|
651
|
+
|
652
|
+
def calabash_2_version
|
624
653
|
version = nil
|
625
654
|
|
655
|
+
if File.exist?(workspace_gemfile)
|
656
|
+
FileUtils.cd(self.workspace) do
|
657
|
+
version = get_calabash_version_from_bundler
|
658
|
+
end
|
659
|
+
end
|
660
|
+
|
661
|
+
unless version
|
662
|
+
require 'calabash'
|
663
|
+
version = Calabash::VERSION
|
664
|
+
end
|
665
|
+
|
666
|
+
version.strip
|
667
|
+
end
|
668
|
+
|
669
|
+
def calabash_android_version
|
670
|
+
if is_calabash_2?
|
671
|
+
return calabash_2_version
|
672
|
+
end
|
673
|
+
|
674
|
+
version = nil
|
626
675
|
|
627
676
|
if File.exist?(workspace_gemfile)
|
628
677
|
FileUtils.cd(self.workspace) do
|
@@ -630,27 +679,35 @@ module XamarinTestCloud
|
|
630
679
|
version = version && version.strip
|
631
680
|
end
|
632
681
|
end
|
682
|
+
|
633
683
|
unless version
|
634
684
|
require 'calabash-android'
|
635
685
|
version = Calabash::Android::VERSION
|
636
686
|
end
|
637
687
|
|
638
|
-
version
|
688
|
+
version.strip
|
639
689
|
end
|
640
690
|
|
641
691
|
def calabash_ios_version
|
692
|
+
if is_calabash_2?
|
693
|
+
return calabash_2_version
|
694
|
+
end
|
695
|
+
|
642
696
|
version = nil
|
697
|
+
|
643
698
|
if File.exist?(workspace_gemfile)
|
644
699
|
FileUtils.cd(self.workspace) do
|
645
700
|
version = `bundle exec ruby -e "require 'calabash-cucumber/version'; puts Calabash::Cucumber::VERSION"`
|
646
701
|
version = version && version.strip
|
647
702
|
end
|
648
703
|
end
|
704
|
+
|
649
705
|
unless version
|
650
706
|
require 'calabash-cucumber'
|
651
707
|
version = Calabash::Cucumber::VERSION
|
652
708
|
end
|
653
|
-
|
709
|
+
|
710
|
+
version.strip
|
654
711
|
end
|
655
712
|
|
656
713
|
def test_server_path
|
@@ -838,17 +895,30 @@ module XamarinTestCloud
|
|
838
895
|
end
|
839
896
|
end
|
840
897
|
|
841
|
-
|
842
898
|
def verify_dependencies(path)
|
843
899
|
if is_android?
|
844
900
|
abort_unless(File.exist?(test_server_path)) do
|
845
|
-
puts
|
846
|
-
|
901
|
+
puts "No test server '#{test_server_path}' found. Please run:"
|
902
|
+
|
903
|
+
if is_calabash_2?
|
904
|
+
puts " calabash build #{app}"
|
905
|
+
else
|
906
|
+
puts " calabash-android build #{app}"
|
907
|
+
end
|
847
908
|
end
|
848
|
-
|
849
|
-
|
850
|
-
|
851
|
-
|
909
|
+
|
910
|
+
if is_calabash_2?
|
911
|
+
calabash_gem = Dir.glob("#{path}/vendor/cache/calabash-*").first
|
912
|
+
abort_unless(calabash_gem) do
|
913
|
+
puts 'calabash was not packaged correct.'
|
914
|
+
puts 'Please tell testcloud@xamarin.com about this bug.'
|
915
|
+
end
|
916
|
+
else
|
917
|
+
calabash_gem = Dir.glob("#{path}/vendor/cache/calabash-android-*").first
|
918
|
+
abort_unless(calabash_gem) do
|
919
|
+
puts 'calabash-android was not packaged correct.'
|
920
|
+
puts 'Please tell testcloud@xamarin.com about this bug.'
|
921
|
+
end
|
852
922
|
end
|
853
923
|
end
|
854
924
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: xamarin-test-cloud
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.0.0.
|
4
|
+
version: 2.0.0.pre4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Karl Krukow
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2016-
|
12
|
+
date: 2016-04-08 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: thor
|
@@ -297,9 +297,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
297
297
|
version: 1.3.1
|
298
298
|
requirements: []
|
299
299
|
rubyforge_project:
|
300
|
-
rubygems_version: 2.
|
300
|
+
rubygems_version: 2.5.2
|
301
301
|
signing_key:
|
302
302
|
specification_version: 4
|
303
303
|
summary: Command-line interface to Xamarin Test Cloud
|
304
304
|
test_files: []
|
305
|
-
has_rdoc:
|