soaspec 0.1.14 → 0.1.15
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitlab-ci.yml +1 -1
- data/ChangeLog +4 -0
- data/Rakefile +6 -0
- data/lib/soaspec/exe_helpers.rb +9 -6
- data/lib/soaspec/generator/spec/spec_helper.rb.erb +1 -1
- data/lib/soaspec/version.rb +1 -1
- data/soaspec.gemspec +1 -0
- metadata +16 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d368c5c827b4d662bf9c82623190c76e33092434
|
4
|
+
data.tar.gz: a1b330c6d528e4a8ad2ba493f88a0315d19539e0
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c06a465ddeb2625c62da9b7663c93b74088aa7d600f3779d652f00d9e6ab6f06db92520152e18edfc44a29fa53adb963cc9df7995b14acd7a69ad2a282015750
|
7
|
+
data.tar.gz: b41b2d21a9168ee41ec1d7fbc849a2523265c81180dc66d50d053388e5c276cf22707d7eff4c2402426db1edd4d3c3f842931162423042ce91d120513ea14c24
|
data/.gitlab-ci.yml
CHANGED
data/ChangeLog
CHANGED
data/Rakefile
CHANGED
@@ -1,6 +1,7 @@
|
|
1
1
|
require 'bundler/gem_tasks'
|
2
2
|
require 'rspec/core/rake_task'
|
3
3
|
require 'rake/clean'
|
4
|
+
require 'yard'
|
4
5
|
|
5
6
|
ENV['folder'] ||= ''
|
6
7
|
ENV['test'] ||= ''
|
@@ -17,8 +18,13 @@ CLOBBER.include 'logs/*'
|
|
17
18
|
|
18
19
|
desc 'Start virtual web service'
|
19
20
|
task :start_test_server do
|
21
|
+
ENV['leave_server_running'] = 'true' # This will stop created suites from killing this service
|
20
22
|
mkdir_p 'logs'
|
21
23
|
ENV['test_server_pid'] = Process.spawn('ruby', 'exe/soaspec', 'virtual_server', err: %w[logs/test_server.log w]).to_s
|
22
24
|
sleep 2 # Wait a little for virtual server to start up
|
23
25
|
puts 'Running test server at pid ' + ENV['test_server_pid']
|
24
26
|
end
|
27
|
+
|
28
|
+
YARD::Rake::YardocTask.new do |t|
|
29
|
+
t.files = %w[features/**/*.feature features/**/*.rb lib/soaspec/cucumber/*.rb] # lib/soaspec/cucumber/*.rb]
|
30
|
+
end
|
data/lib/soaspec/exe_helpers.rb
CHANGED
@@ -9,18 +9,21 @@ module Soaspec
|
|
9
9
|
def create_files_for(type)
|
10
10
|
case type
|
11
11
|
when 'soap'
|
12
|
-
|
13
|
-
create_file filename: 'lib/shared_example.rb'
|
12
|
+
create_files %w[lib/blz_service.rb lib/shared_example.rb spec/soap_spec.rb]
|
14
13
|
create_file(filename: 'template/soap_template.xml', erb: false)
|
15
|
-
create_file(filename: 'spec/soap_spec.rb')
|
16
14
|
when 'rest'
|
17
|
-
|
18
|
-
create_file(filename: 'lib/package_service.rb')
|
15
|
+
create_files %w[spec/rest_spec.rb lib/package_service.rb]
|
19
16
|
else
|
20
17
|
# TODO: This needs to have placeholders explaining what to fill in
|
21
18
|
end
|
22
19
|
end
|
23
20
|
|
21
|
+
# @param [Array] filenames List of files to create
|
22
|
+
def create_files(filenames)
|
23
|
+
raise ArgumentError, 'Expected filenames to be an Array' unless filenames.is_a? Array
|
24
|
+
filenames.each { |name| create_file filename: name }
|
25
|
+
end
|
26
|
+
|
24
27
|
# Spec task string depending upon whether virtual is used
|
25
28
|
def spec_task
|
26
29
|
task_name = options[:virtual] ? 'spec: :start_test_server' : ':spec'
|
@@ -63,7 +66,7 @@ module Soaspec
|
|
63
66
|
end
|
64
67
|
end
|
65
68
|
|
66
|
-
# Create class representing wsdl in general
|
69
|
+
# @return [String] Create class representing wsdl in general
|
67
70
|
def class_content
|
68
71
|
ERB.new(File.read(File.join(File.dirname(__FILE__), 'generator', 'lib/dynamic_class_content.rb.erb'))).result(binding)
|
69
72
|
end
|
@@ -17,7 +17,7 @@ RSpec.configure do |config|
|
|
17
17
|
<% if @virtual %>
|
18
18
|
# Close test server after all RSpec tests have run
|
19
19
|
config.after(:suite) do
|
20
|
-
Process.kill(:QUIT, ENV['test_server_pid'].to_i) if ENV['test_server_pid']
|
20
|
+
Process.kill(:QUIT, ENV['test_server_pid'].to_i) if ENV['test_server_pid'] && !ENV['leave_server_running']
|
21
21
|
end
|
22
22
|
<% end %>
|
23
23
|
end
|
data/lib/soaspec/version.rb
CHANGED
data/soaspec.gemspec
CHANGED
@@ -30,6 +30,7 @@ the same configuration "
|
|
30
30
|
spec.add_development_dependency 'require_all', '1.5.0'
|
31
31
|
spec.add_development_dependency 'rspec', '~> 3.0'
|
32
32
|
spec.add_development_dependency 'simplecov'
|
33
|
+
spec.add_development_dependency 'yard-cucumber'
|
33
34
|
spec.add_dependency 'activesupport'
|
34
35
|
spec.add_dependency 'faker'
|
35
36
|
spec.add_dependency 'hashie'
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: soaspec
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.15
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- SamuelGarrattIQA
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-
|
11
|
+
date: 2018-11-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -122,6 +122,20 @@ dependencies:
|
|
122
122
|
- - ">="
|
123
123
|
- !ruby/object:Gem::Version
|
124
124
|
version: '0'
|
125
|
+
- !ruby/object:Gem::Dependency
|
126
|
+
name: yard-cucumber
|
127
|
+
requirement: !ruby/object:Gem::Requirement
|
128
|
+
requirements:
|
129
|
+
- - ">="
|
130
|
+
- !ruby/object:Gem::Version
|
131
|
+
version: '0'
|
132
|
+
type: :development
|
133
|
+
prerelease: false
|
134
|
+
version_requirements: !ruby/object:Gem::Requirement
|
135
|
+
requirements:
|
136
|
+
- - ">="
|
137
|
+
- !ruby/object:Gem::Version
|
138
|
+
version: '0'
|
125
139
|
- !ruby/object:Gem::Dependency
|
126
140
|
name: activesupport
|
127
141
|
requirement: !ruby/object:Gem::Requirement
|