hiptest-publisher 1.0.1 → 1.1.0
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/hiptest-publisher.rb +29 -0
- data/lib/hiptest-publisher/options_parser.rb +2 -2
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 0dd96ca916a6a6a1ffaf84dc10e4bb922302997c
|
4
|
+
data.tar.gz: f794c24f62cf44521dacde5bc3f166aa12a0ca8c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1a0ab6b3cc0d7e7ee5d8bf213ba715a628ff1989ec73bfa608c4c322acd5a77b9fe9592575ea5562632a3ccf0eff39c57e80eb89a481dbe7059205f080fa653f
|
7
|
+
data.tar.gz: 1842dc3d968c8ee5481ea8b1d4a25c4b22a4b711c58e411b5fb8b7ef353309264042b67023dc6a378e97b78028c3d456b7d6430adf7c1a89b099cc3b36d7f875
|
data/README.md
CHANGED
@@ -117,7 +117,7 @@ Specific options:
|
|
117
117
|
--show-actionwords-definition-changed
|
118
118
|
Output action words for which definition changed (default: false)
|
119
119
|
--with-folders Use folders hierarchy to export files in respective directories (default: false)
|
120
|
-
--split-scenarios Export each scenario in a single file
|
120
|
+
--split-scenarios Export each scenario in a single file (except for Gherkin based languages) (default: false)
|
121
121
|
--leafless-export Use only last level action word (default: false)
|
122
122
|
-s, --site=SITE Site to fetch from (default: https://hiptest.net)
|
123
123
|
-p, --push=FILE.TAP Push a results file to the server
|
data/lib/hiptest-publisher.rb
CHANGED
@@ -32,6 +32,11 @@ module Hiptest
|
|
32
32
|
end
|
33
33
|
|
34
34
|
def run
|
35
|
+
if @cli_options.check_version
|
36
|
+
check_version
|
37
|
+
return
|
38
|
+
end
|
39
|
+
|
35
40
|
begin
|
36
41
|
CliOptionsChecker.new(@cli_options, reporter).check!
|
37
42
|
rescue CliOptionError => e
|
@@ -296,6 +301,30 @@ module Hiptest
|
|
296
301
|
].join("\n")
|
297
302
|
end
|
298
303
|
|
304
|
+
def check_version
|
305
|
+
latest = nil
|
306
|
+
reporter.with_status_message "Checking latest version on Rubygem" do
|
307
|
+
latest_gem = Gem.latest_version_for('hiptest-publisher')
|
308
|
+
|
309
|
+
raise RuntimeError, "Unable to connect to Rubygem" if latest_gem.nil?
|
310
|
+
|
311
|
+
latest = latest_gem.version
|
312
|
+
end
|
313
|
+
|
314
|
+
return if latest.nil?
|
315
|
+
|
316
|
+
current = hiptest_publisher_version
|
317
|
+
|
318
|
+
if latest == current
|
319
|
+
puts "Your current install of hiptest-publisher (#{current}) is up-to-date."
|
320
|
+
else
|
321
|
+
puts [
|
322
|
+
"Your current install of hiptest-publisher (#{current}) is outdated, version #{latest} is available",
|
323
|
+
"run 'gem install hiptest-publisher' to get the latest version."
|
324
|
+
].join("\n")
|
325
|
+
end
|
326
|
+
end
|
327
|
+
|
299
328
|
def post_results
|
300
329
|
response = nil
|
301
330
|
reporter.with_status_message "Posting #{@cli_options.push} to #{@cli_options.site}" do
|
@@ -208,7 +208,7 @@ class OptionsParser
|
|
208
208
|
Option.new(nil, 'show-actionwords-signature-changed', false, nil, "Output signatures of action words for which signature changed", :aw_signature_changed),
|
209
209
|
Option.new(nil, 'show-actionwords-definition-changed', false, nil, "Output action words for which definition changed", :aw_definition_changed),
|
210
210
|
Option.new(nil, 'with-folders', false, nil, "Use folders hierarchy to export files in respective directories", :with_folders),
|
211
|
-
Option.new(nil, 'split-scenarios', false, nil, "Export each scenario in a single file
|
211
|
+
Option.new(nil, 'split-scenarios', false, nil, "Export each scenario in a single file (except for Gherkin based languages)", :split_scenarios),
|
212
212
|
Option.new(nil, 'leafless-export', false, nil, "Use only last level action word", :leafless_export),
|
213
213
|
Option.new('s', 'site=SITE', 'https://hiptest.net', String, "Site to fetch from", :site),
|
214
214
|
Option.new('p', 'push=FILE.TAP', '', String, "Push a results file to the server", :push),
|
@@ -223,7 +223,7 @@ class OptionsParser
|
|
223
223
|
Option.new(nil, 'filter-on-folder-name=NAME', '', String, "Filter on folder name (only one name is accepted)", :filter_on_folder_name),
|
224
224
|
Option.new(nil, 'filter-on-tags=TAGS', '', String, "Filter on scenarios and folder tags (use commas to separate tags when using multiple tags)", :filter_on_tags),
|
225
225
|
Option.new(nil, 'filter-on-status=STATUS', '', String, "Filter on test status in last build (use in conjunction with a test run)", :filter_on_status),
|
226
|
-
|
226
|
+
Option.new(nil, 'check-version', false, nil, "Check if a new release of hiptest-publisher is available", :check_version),
|
227
227
|
Option.new('v', 'verbose', false, nil, "Run verbosely", :verbose)
|
228
228
|
]
|
229
229
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: hiptest-publisher
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0
|
4
|
+
version: 1.1.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Hiptest R&D
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-04-
|
11
|
+
date: 2017-04-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: colorize
|
@@ -596,7 +596,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
596
596
|
version: '0'
|
597
597
|
requirements: []
|
598
598
|
rubyforge_project:
|
599
|
-
rubygems_version: 2.
|
599
|
+
rubygems_version: 2.5.1
|
600
600
|
signing_key:
|
601
601
|
specification_version: 4
|
602
602
|
summary: Export your tests from Hiptest into executable tests.
|