cukehub 0.8.5 → 0.8.7

Sign up to get free protection for your applications and to get access to all the features.
Files changed (4) hide show
  1. checksums.yaml +4 -4
  2. data/lib/tasks/cukehub.rake +20 -0
  3. metadata +2 -2
  4. data/lib/cukehub.rb +0 -34
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 373b6a0310ea235f95bac8df47be8a693b2d7dbc
4
- data.tar.gz: 5a709d5a72b177385f75499f028a36a97297e54d
3
+ metadata.gz: 57eeb1a1c036c07638e8d8bcfdb25173569bb478
4
+ data.tar.gz: 3c69a574845150113edb036bd3964ab490f25755
5
5
  SHA512:
6
- metadata.gz: 1ec1e02cb907ea2e942b457e1abe19290de02542d754befc6a822a05fb0468f3ec85893ea783a7abc41cb5c368e59f713d62aa8a3ba6f1be0c178e226e0ca3c9
7
- data.tar.gz: c52c997933ea239136911e44d96f6bfe22fd9dfe2a1371a0f954b974592a91e68767d15c49c866ba88e9fc81872f2a303adc7093a98fefc5bc18002b611d5cd6
6
+ metadata.gz: 91c5b1f7383afd68b454572025eba3b34d25ee57fb143da28280c1d2bed75478f847b22af13d02d22b399bec9032313d674daab459786c6223eae98ac3f54de6
7
+ data.tar.gz: f96ca053a1cb0a09b7cbf89e6c7009f5c56721fb9d78a899af128ae4666eeb81b9ca80c09c258b65c96b15d764c34a4f89df862736f027766328d95a18ace470
@@ -0,0 +1,20 @@
1
+ require 'rubygems'
2
+
3
+ namespace :cuke do
4
+ desc "cucunber -t <@tags> against qa.cloudchecker.com"
5
+ task :hub, [:tag] do |t, args|
6
+ file = "#{args[:tag]}".gsub(/@/, '')
7
+ Bundler.with_clean_env do
8
+ console_output = ""
9
+ IO.popen("thor set:chrome_ci && cucumber -t #{args[:tag]} -f rerun --out #{file}.txt", 'r+') do |pipe|
10
+ puts console_output = pipe.read
11
+ pipe.close_write
12
+ end
13
+ IO.popen("cucumber #{args[:tag]}.txt --format html --out=#{file}.html --format pretty", 'r+') do |pipe|
14
+ puts "** RE-RUNNING FAILED #{args[:tags]}.txt SCENARIOS **"
15
+ puts console_output = pipe.read
16
+ pipe.close_write
17
+ end
18
+ end
19
+ end
20
+ end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cukehub
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.8.5
4
+ version: 0.8.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Rich Downie
@@ -58,7 +58,7 @@ executables: []
58
58
  extensions: []
59
59
  extra_rdoc_files: []
60
60
  files:
61
- - lib/cukehub.rb
61
+ - lib/tasks/cukehub.rake
62
62
  homepage: http://cukehub.com
63
63
  licenses:
64
64
  - MIT
data/lib/cukehub.rb DELETED
@@ -1,34 +0,0 @@
1
- require 'httparty'
2
- require 'os'
3
-
4
- if OS.mac? then
5
- os = "OSX"
6
- elsif OS.linux?
7
- os = "Linux"
8
- elsif OS.doze?
9
- os = "Win"
10
- end
11
-
12
- Before do
13
- @start = Time.now
14
- end
15
-
16
- After do |scenario|
17
- IO.popen("git symbolic-ref --short HEAD") {|pipe| puts @git_branch = pipe.read }
18
- params = {
19
- token: @cukehub_token,
20
- name: scenario.name,
21
- location: scenario.location,
22
- tag: scenario.source_tag_names,
23
- status: scenario.status.upcase,
24
- machine: Socket.gethostname,
25
- os: os,
26
- runtime: (Time.now - @start),
27
- domain: @domain,
28
- branch: @git_branch.chomp
29
- }
30
- params[:browser] = @browser.browser.upcase unless @browser.nil?
31
- params[:exception]=scenario.exception.message unless scenario.passed?
32
-
33
- HTTParty.post("http://cukehub.com/dropin", body: params)
34
- end