soaspec 0.2.24 → 0.2.25

Sign up to get free protection for your applications and to get access to all the features.
Files changed (83) hide show
  1. checksums.yaml +5 -5
  2. data/.gitignore +15 -15
  3. data/.gitlab-ci.yml +51 -33
  4. data/.rspec +3 -3
  5. data/.rubocop.yml +2 -2
  6. data/CODE_OF_CONDUCT.md +74 -74
  7. data/ChangeLog +588 -577
  8. data/Gemfile +6 -6
  9. data/LICENSE.txt +21 -21
  10. data/README.md +230 -230
  11. data/Rakefile +50 -42
  12. data/Todo.md +15 -15
  13. data/exe/soaspec +137 -123
  14. data/exe/xml_to_yaml_file +42 -42
  15. data/lib/soaspec.rb +103 -101
  16. data/lib/soaspec/core_ext/hash.rb +42 -35
  17. data/lib/soaspec/cucumber/generic_steps.rb +85 -85
  18. data/lib/soaspec/demo.rb +4 -4
  19. data/lib/soaspec/exchange/exchange.rb +117 -111
  20. data/lib/soaspec/exchange/exchange_extractor.rb +83 -83
  21. data/lib/soaspec/exchange/exchange_properties.rb +26 -26
  22. data/lib/soaspec/exchange/exchange_repeater.rb +19 -19
  23. data/lib/soaspec/exchange/request_builder.rb +68 -68
  24. data/lib/soaspec/exchange/variable_storer.rb +22 -22
  25. data/lib/soaspec/exchange_handlers/exchange_handler.rb +130 -126
  26. data/lib/soaspec/exchange_handlers/handler_accessors.rb +130 -130
  27. data/lib/soaspec/exchange_handlers/request/rest_request.rb +49 -0
  28. data/lib/soaspec/exchange_handlers/request/soap_request.rb +39 -0
  29. data/lib/soaspec/exchange_handlers/response_extractor.rb +82 -82
  30. data/lib/soaspec/exchange_handlers/rest_exchanger_factory.rb +109 -109
  31. data/lib/soaspec/exchange_handlers/rest_handler.rb +287 -259
  32. data/lib/soaspec/exchange_handlers/rest_methods.rb +63 -44
  33. data/lib/soaspec/exchange_handlers/rest_parameters.rb +90 -86
  34. data/lib/soaspec/exchange_handlers/rest_parameters_defaults.rb +40 -21
  35. data/lib/soaspec/exchange_handlers/soap_handler.rb +239 -235
  36. data/lib/soaspec/exe_helpers.rb +92 -92
  37. data/lib/soaspec/generate_server.rb +46 -37
  38. data/lib/soaspec/generator/.rspec.erb +5 -5
  39. data/lib/soaspec/generator/.travis.yml.erb +5 -5
  40. data/lib/soaspec/generator/Gemfile.erb +8 -8
  41. data/lib/soaspec/generator/README.md.erb +29 -29
  42. data/lib/soaspec/generator/Rakefile.erb +19 -19
  43. data/lib/soaspec/generator/config/data/default.yml.erb +2 -2
  44. data/lib/soaspec/generator/css/bootstrap.css +6833 -6833
  45. data/lib/soaspec/generator/features/support/env.rb.erb +3 -0
  46. data/lib/soaspec/generator/generate_exchange.html.erb +47 -35
  47. data/lib/soaspec/generator/lib/blz_service.rb.erb +26 -26
  48. data/lib/soaspec/generator/lib/dynamic_class_content.rb.erb +12 -12
  49. data/lib/soaspec/generator/lib/new_rest_service.rb.erb +56 -51
  50. data/lib/soaspec/generator/lib/new_soap_service.rb.erb +29 -29
  51. data/lib/soaspec/generator/lib/package_service.rb.erb +2 -2
  52. data/lib/soaspec/generator/lib/shared_example.rb.erb +8 -8
  53. data/lib/soaspec/generator/spec/dynamic_soap_spec.rb.erb +12 -12
  54. data/lib/soaspec/generator/spec/rest_spec.rb.erb +9 -9
  55. data/lib/soaspec/generator/spec/soap_spec.rb.erb +51 -51
  56. data/lib/soaspec/generator/spec/spec_helper.rb.erb +23 -23
  57. data/lib/soaspec/generator/template/soap_template.xml +6 -6
  58. data/lib/soaspec/indifferent_hash.rb +7 -7
  59. data/lib/soaspec/interpreter.rb +39 -39
  60. data/lib/soaspec/matchers.rb +114 -114
  61. data/lib/soaspec/not_found_errors.rb +13 -13
  62. data/lib/soaspec/o_auth2.rb +128 -128
  63. data/lib/soaspec/soaspec_shared_examples.rb +24 -24
  64. data/lib/soaspec/spec_logger.rb +122 -121
  65. data/lib/soaspec/template_reader.rb +28 -28
  66. data/lib/soaspec/test_server/bank.wsdl +90 -90
  67. data/lib/soaspec/test_server/get_bank.rb +164 -164
  68. data/lib/soaspec/test_server/id_manager.rb +39 -39
  69. data/lib/soaspec/test_server/invoices.rb +27 -27
  70. data/lib/soaspec/test_server/namespace.xml +14 -14
  71. data/lib/soaspec/test_server/note.xml +5 -5
  72. data/lib/soaspec/test_server/puppy_service.rb +19 -19
  73. data/lib/soaspec/test_server/test_attribute.rb +12 -12
  74. data/lib/soaspec/test_server/test_namespace.rb +12 -12
  75. data/lib/soaspec/version.rb +4 -4
  76. data/lib/soaspec/virtual_server.rb +174 -174
  77. data/lib/soaspec/wait.rb +41 -41
  78. data/lib/soaspec/wsdl_generator.rb +215 -215
  79. data/soaspec.gemspec +56 -53
  80. data/test.wsdl +116 -116
  81. data/test.xml +10 -10
  82. data/test_wsdl.rb +41 -41
  83. metadata +38 -6
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
- SHA256:
3
- metadata.gz: 536c7c0e17d7326f88ee6713442c0fcdd78c83ee0dfe31397ee3231fd9a20c1a
4
- data.tar.gz: 263c87c2b41c763c5fa196f02591955fefa86f48cee9f5910a1cf6195a476b43
2
+ SHA1:
3
+ metadata.gz: 3e05f737b159b34765390c9e79d2fa63c3f38224
4
+ data.tar.gz: b0b6698390955dd891e546e8d23a73b06aa5a494
5
5
  SHA512:
6
- metadata.gz: 8f4f7d0d6b55b213c41aeca86bb667c922a9fd003d5d5a9550957df4a723863433cc0b9ba8c79407795641653ab6807f00f168118c47ea74c352604aed7d8432
7
- data.tar.gz: bee52426bc53cba71d1e2f7b5d6c39b4652d5f64badab17d6842efca51f1bbde9ffdfd4f8e00c7b109bf7d5a59249bcda4381c4d8036b9aaffb571acd6ab6477
6
+ metadata.gz: 565dd25349cb90c5c15064a0040f3ce503c74e1f522f42c0329dc8cd02ba1ae5c7a64321711438ad6c09418428606a6c8ef76fad8c5a114f3a88625f0eaed198
7
+ data.tar.gz: 41c2cc405ee6a1fc8e86929cd00a91b30ce2f9abcd71caa4fc3b024ce3d157c43d99e2b58ba701a96e572f71d520a3b49c2df78341d9dbe16d9ffa609851ccec
data/.gitignore CHANGED
@@ -1,15 +1,15 @@
1
- /.bundle/
2
- /.yardoc
3
- /_yardoc/
4
- /coverage/
5
- /doc/
6
- /logs/
7
- /pkg/
8
- /spec/reports/
9
- /tmp/
10
- /.idea/
11
- Gemfile.lock
12
- coverage
13
-
14
- # rspec failure tracking
15
- .rspec_status
1
+ /.bundle/
2
+ /.yardoc
3
+ /_yardoc/
4
+ /coverage/
5
+ /doc/
6
+ /logs/
7
+ /pkg/
8
+ /spec/reports/
9
+ /tmp/
10
+ /.idea/
11
+ Gemfile.lock
12
+ coverage
13
+
14
+ # rspec failure tracking
15
+ .rspec_status
data/.gitlab-ci.yml CHANGED
@@ -1,34 +1,52 @@
1
- image: ruby:2.5
2
-
3
- before_script:
4
- - ruby -v
5
- - which ruby
6
- - gem install bundler rake
7
- - bundle install --jobs $(nproc) "${FLAGS[@]}"
8
-
9
- rspec:
10
- stage: test
11
- script:
12
- - bundle exec rake spec
13
- artifacts:
14
- paths:
15
- - coverage/
16
-
17
- cucumber:
18
- stage: test
19
- script:
20
- - bundle exec cucumber
21
-
22
- pages:
23
- stage: deploy
24
- dependencies:
25
- - rspec
26
- script:
27
- - mv demo/ public/
28
- - mv coverage/ public/coverage
29
- artifacts:
30
- paths:
31
- - public
32
- expire_in: 30 days
33
- only:
1
+ image: ruby:2.5
2
+
3
+ before_script:
4
+ - ruby -v
5
+ - which ruby
6
+ - gem install bundler rake
7
+ - bundle install --jobs $(nproc) "${FLAGS[@]}"
8
+
9
+ ruby_2.3:
10
+ stage: test
11
+ image: ruby:2.3
12
+ script:
13
+ - bundle exec rake spec
14
+
15
+ ruby_2.4:
16
+ stage: test
17
+ image: ruby:2.4
18
+ script:
19
+ - bundle exec rake spec
20
+
21
+ ruby_2.5:
22
+ stage: test
23
+ image: ruby:2.5
24
+ script:
25
+ - bundle exec rake spec
26
+ artifacts:
27
+ paths:
28
+ - coverage/
29
+
30
+ cucumber:
31
+ stage: test
32
+ script:
33
+ - bundle exec cucumber
34
+
35
+ doctest:
36
+ stage: test
37
+ script:
38
+ - bundle exec rake yard:doctest
39
+
40
+ pages:
41
+ stage: deploy
42
+ dependencies:
43
+ - ruby_2.5
44
+ script:
45
+ - mv demo/ public/
46
+ - mv coverage/ public/coverage
47
+ artifacts:
48
+ paths:
49
+ - public
50
+ expire_in: 30 days
51
+ only:
34
52
  - master
data/.rspec CHANGED
@@ -1,3 +1,3 @@
1
- --require spec_helper
2
- --format documentation
3
- --color
1
+ --require spec_helper
2
+ --format documentation
3
+ --color
data/.rubocop.yml CHANGED
@@ -1,2 +1,2 @@
1
- Metrics/LineLength:
2
- Max: 154
1
+ Metrics/LineLength:
2
+ Max: 154
data/CODE_OF_CONDUCT.md CHANGED
@@ -1,74 +1,74 @@
1
- # Contributor Covenant Code of Conduct
2
-
3
- ## Our Pledge
4
-
5
- In the interest of fostering an open and welcoming environment, we as
6
- contributors and maintainers pledge to making participation in our project and
7
- our community a harassment-free experience for everyone, regardless of age, body
8
- size, disability, ethnicity, gender identity and expression, level of experience,
9
- nationality, personal appearance, race, religion, or sexual identity and
10
- orientation.
11
-
12
- ## Our Standards
13
-
14
- Examples of behavior that contributes to creating a positive environment
15
- include:
16
-
17
- * Using welcoming and inclusive language
18
- * Being respectful of differing viewpoints and experiences
19
- * Gracefully accepting constructive criticism
20
- * Focusing on what is best for the community
21
- * Showing empathy towards other community members
22
-
23
- Examples of unacceptable behavior by participants include:
24
-
25
- * The use of sexualized language or imagery and unwelcome sexual attention or
26
- advances
27
- * Trolling, insulting/derogatory comments, and personal or political attacks
28
- * Public or private harassment
29
- * Publishing others' private information, such as a physical or electronic
30
- address, without explicit permission
31
- * Other conduct which could reasonably be considered inappropriate in a
32
- professional setting
33
-
34
- ## Our Responsibilities
35
-
36
- Project maintainers are responsible for clarifying the standards of acceptable
37
- behavior and are expected to take appropriate and fair corrective action in
38
- response to any instances of unacceptable behavior.
39
-
40
- Project maintainers have the right and responsibility to remove, edit, or
41
- reject comments, commits, code, wiki edits, issues, and other contributions
42
- that are not aligned to this Code of Conduct, or to ban temporarily or
43
- permanently any contributor for other behaviors that they deem inappropriate,
44
- threatening, offensive, or harmful.
45
-
46
- ## Scope
47
-
48
- This Code of Conduct applies both within project spaces and in public spaces
49
- when an individual is representing the project or its community. Examples of
50
- representing a project or community include using an official project e-mail
51
- address, posting via an official social media account, or acting as an appointed
52
- representative at an online or offline event. Representation of a project may be
53
- further defined and clarified by project maintainers.
54
-
55
- ## Enforcement
56
-
57
- Instances of abusive, harassing, or otherwise unacceptable behavior may be
58
- reported by contacting the project team at samuel.garratt@integrationqa.com. All
59
- complaints will be reviewed and investigated and will result in a response that
60
- is deemed necessary and appropriate to the circumstances. The project team is
61
- obligated to maintain confidentiality with regard to the reporter of an incident.
62
- Further details of specific enforcement policies may be posted separately.
63
-
64
- Project maintainers who do not follow or enforce the Code of Conduct in good
65
- faith may face temporary or permanent repercussions as determined by other
66
- members of the project's leadership.
67
-
68
- ## Attribution
69
-
70
- This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
71
- available at [http://contributor-covenant.org/version/1/4][version]
72
-
73
- [homepage]: http://contributor-covenant.org
74
- [version]: http://contributor-covenant.org/version/1/4/
1
+ # Contributor Covenant Code of Conduct
2
+
3
+ ## Our Pledge
4
+
5
+ In the interest of fostering an open and welcoming environment, we as
6
+ contributors and maintainers pledge to making participation in our project and
7
+ our community a harassment-free experience for everyone, regardless of age, body
8
+ size, disability, ethnicity, gender identity and expression, level of experience,
9
+ nationality, personal appearance, race, religion, or sexual identity and
10
+ orientation.
11
+
12
+ ## Our Standards
13
+
14
+ Examples of behavior that contributes to creating a positive environment
15
+ include:
16
+
17
+ * Using welcoming and inclusive language
18
+ * Being respectful of differing viewpoints and experiences
19
+ * Gracefully accepting constructive criticism
20
+ * Focusing on what is best for the community
21
+ * Showing empathy towards other community members
22
+
23
+ Examples of unacceptable behavior by participants include:
24
+
25
+ * The use of sexualized language or imagery and unwelcome sexual attention or
26
+ advances
27
+ * Trolling, insulting/derogatory comments, and personal or political attacks
28
+ * Public or private harassment
29
+ * Publishing others' private information, such as a physical or electronic
30
+ address, without explicit permission
31
+ * Other conduct which could reasonably be considered inappropriate in a
32
+ professional setting
33
+
34
+ ## Our Responsibilities
35
+
36
+ Project maintainers are responsible for clarifying the standards of acceptable
37
+ behavior and are expected to take appropriate and fair corrective action in
38
+ response to any instances of unacceptable behavior.
39
+
40
+ Project maintainers have the right and responsibility to remove, edit, or
41
+ reject comments, commits, code, wiki edits, issues, and other contributions
42
+ that are not aligned to this Code of Conduct, or to ban temporarily or
43
+ permanently any contributor for other behaviors that they deem inappropriate,
44
+ threatening, offensive, or harmful.
45
+
46
+ ## Scope
47
+
48
+ This Code of Conduct applies both within project spaces and in public spaces
49
+ when an individual is representing the project or its community. Examples of
50
+ representing a project or community include using an official project e-mail
51
+ address, posting via an official social media account, or acting as an appointed
52
+ representative at an online or offline event. Representation of a project may be
53
+ further defined and clarified by project maintainers.
54
+
55
+ ## Enforcement
56
+
57
+ Instances of abusive, harassing, or otherwise unacceptable behavior may be
58
+ reported by contacting the project team at samuel.garratt@integrationqa.com. All
59
+ complaints will be reviewed and investigated and will result in a response that
60
+ is deemed necessary and appropriate to the circumstances. The project team is
61
+ obligated to maintain confidentiality with regard to the reporter of an incident.
62
+ Further details of specific enforcement policies may be posted separately.
63
+
64
+ Project maintainers who do not follow or enforce the Code of Conduct in good
65
+ faith may face temporary or permanent repercussions as determined by other
66
+ members of the project's leadership.
67
+
68
+ ## Attribution
69
+
70
+ This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
71
+ available at [http://contributor-covenant.org/version/1/4][version]
72
+
73
+ [homepage]: http://contributor-covenant.org
74
+ [version]: http://contributor-covenant.org/version/1/4/
data/ChangeLog CHANGED
@@ -1,578 +1,589 @@
1
- Version 0.2.24
2
- * Bug Fix
3
- * Be explicit about where shared_examples_for is from (RSpec) as it can cause loading issues
4
-
5
- Version 0.2.23
6
- * Enhancement
7
- * Interpreter handles XML Doc
8
- * Get document_type_for complex element working. Hopefully should be able to handle WSDL with large response now
9
-
10
- Version 0.2.22
11
- * Bug Fix
12
- * Allow negated version of 'be_successful' to work
13
- * Fix `Exchange.retry_count` so that it retries after first try the correct number of times
14
- * Enhancement
15
- * Make 'value_from_path' and 'values_from_path' methods accessible from 'response' object
16
- * Get extracting text via RegEx actually working
17
-
18
- Version 0.2.21
19
- * Enhancement
20
- * Enable deprecation warnings to be removed so that they're not annoying with `Soaspec.log_warnings`
21
-
22
- Version 0.2.20
23
- * Enhancement
24
- * 'soaspec pry' command to open pry, loading test API classes
25
-
26
- Version 0.2.19
27
- * Enhancement
28
- * Create 'soaspec generate' (without wsdl) as a way to create an ExchangeHandler from a Web Page
29
-
30
- Version 0.2.18
31
- * Enhancement
32
- * Hash of body returned via 'to_hash' can be accessed through Symbol or String
33
-
34
- Version 0.2.17
35
- * Bug Fix
36
- * Correct Output where does not show the conversion happening by JSONPath and PascalCase conversion
37
-
38
- Version 0.2.16
39
- * Enhancement
40
- * Move debug oauth into OAuth2 class
41
-
42
- Version 0.2.14
43
- * Bug Fix
44
- * Remove default log file being created before it is changed to a custom location
45
-
46
- Version 0.2.13
47
- * Enhancements
48
- * Allow terminal logging color to be changed through a `terminal_color` attribute
49
-
50
- Version 0.2.12
51
- * Enhancements
52
- * Make it easier to set 'traffic_file' location with `Soaspec::SpecLogger.traffic_file = ''`
53
-
54
- Version 0.2.11
55
- * Bug Fix
56
- * Cache 'Soaspec::OAuth2.instance_url' so Access token server not called everytime it's needed
57
-
58
- Version 0.2.10
59
- * Enhancements
60
- * Added 'soaspec/demo' to be required to simplify demoing
61
- * Bug Fix
62
- * Logging wasn't handling Rest log properly
63
-
64
- Version 0.2.9
65
- * Enhancements
66
- * More documentation in README.md
67
- * Started breaking up massive RestHandler more
68
- * Allow one output logs to STDOUT through Soaspec::SpecLogger.output_to_terminal = true
69
-
70
- Version 0.2.8
71
- * Bug Fix
72
- * RSpec-its dependency produces a conflict. Remove specific version reference
73
-
74
- Version 0.2.7
75
- * Bug Fix
76
- * Fix log issue that was failing in Windows
77
-
78
- Version 0.2.6
79
- * Enhancements
80
- * New log file created with time stamp each time tests are run
81
-
82
- Version 0.2.5
83
- * Bug fix
84
- * Error wasn't throw if checking for element with empty response
85
- * Default hash set on Exchange without example overriding value not setting request body
86
-
87
- Version 0.2.4
88
- * Enhancements
89
- * Enable block to be used when creating exchange with Handler.exchange
90
-
91
- Version 0.2.3
92
- * Enhancements
93
- * Exchange.until itself method returns itself making it easier to reuse last result in assertions
94
- * Added parameters to Exchange.until so that timeout, message and interval can be specified
95
- * Soaspec cucumber exe to add generic steps to step_definitions folder
96
-
97
- Version 0.2.2
98
- * Enhancements
99
- * Make accessing test_values from template using indifferent access
100
-
101
- Version 0.2.1
102
- * Enhancements
103
- * Make method to access 'client_id' within a class after specifying 'oauth2_file' to remove unnecessarily loading file twice
104
-
105
- Version 0.2.0
106
- * Exception handling
107
- * Raise meaningful exception if REST header value passed is null
108
- * Enhancements
109
- * `soaspec add` exe to create basic 'rest' or 'soap' service
110
- * Add another matcher to check response is successful
111
- * Default hash and template_name can now be defined within a class rather than just at an instance of it
112
- * Stubs making it clearer what parameters are when looking at code from RubyMine
113
- * Basic auth file method on RestHandler for clearer defining of basic auth
114
- * Handle ERB in 'base_url' method
115
-
116
- Version 0.1.18
117
- * Enhancements
118
- * Define 'exchange' method on response object so original exchange can be accessed
119
- * Make simply approach for setting body of request with just a string passed `ExchangeHandler.post(message_body)` where message_body is not
120
- a `Hash` but a `String`
121
-
122
- Version 0.1.17
123
- * Enhancements
124
- * Added Wait class to easily wait for an expected condition to be true, either using global Soaspec::Wait or `exchange.until { true }`
125
- See spec/unit/wait_spec for example
126
- * Made shorter way to `get` a REST url with `RestHandler.get 'id'` setting the suburl to 'id' automatically
127
-
128
- Version 0.1.16
129
- * Bug fix
130
- * Retry was not working for OAuth access_token
131
-
132
- Version 0.1.15
133
- * Enhancements
134
- * Added more unit test coverage and a few more comments
135
-
136
- Version 0.1.14
137
- * Enhancements
138
- * Got `rest` soaspec new working
139
-
140
- Version 0.1.13
141
- * Enhancements
142
- * Cleaned up comments (mainly OAuth2 related)
143
- * Cleaned up REST handler code, adding more comments on usage
144
- * Added 'soaspec/cucumber/generic_steps' to simplify reusing code and also demonstrate how gem can be used
145
-
146
- Version 0.1.12
147
- * Enhancements
148
- * Add 'refresh_token' attribute to Soaspec::OAuth2 class so that token can be retrieved once and then stored
149
-
150
- Version 0.1.11
151
- * Enhancements
152
- * OAuth2 class can be initialized with strings as keys
153
- * Global attribute, 'Soaspec::OAuth2.token_url' for setting common value
154
-
155
- Version 0.1.10
156
- * Enhancements
157
- * Rename default template folder from to 'template' to 'templates'
158
- * Use TemplateReader to simplify and add error handling to extracting templates
159
- * Got convenience Rest Methods able to handle taking in template_name
160
- * Started making a 'request' method to access request of API actually sent
161
-
162
- Version 0.1.9
163
- * Enhancements
164
- * Finally move `soaspec-virtual-server` into same binary as `soaspec` utilising Thor
165
-
166
- Version 0.1.8
167
- * Bug fix
168
- * Could not see OAuth parameters sent in logs when setting oauth debugging to true
169
-
170
- Version 0.1.7
171
- * Enhancements
172
- * Include access token header automatically if 'authorization' is not set. Turn off with `Soaspec.auto_oauth = false`
173
-
174
- Version 0.1.6
175
- * Enhancements
176
- * Bind localhost to 0.0.0.0 so service is accessible outside localhost
177
-
178
- Version 0.1.5
179
- * Enhancements
180
- * Package spec changes status after a post is made. Help to illustrate scenario where status changes
181
- * Record last exchange made for debugging purposes in 'last_exchange'
182
-
183
- Version 0.1.4
184
- * Enhancements
185
- * create_file method create folders automatically if necessary
186
- * Package spec to help learn testing for items in a list
187
- * Added docs for soaspec-virtual-server
188
-
189
- Version 0.1.3
190
- * Enhancements
191
- * Ability to set template folder
192
- * Json Path handle multiple paths separated by commas
193
-
194
- Version 0.1.1
195
- * Enhancements
196
- * Added ability to turn off logs (helpful if making a lot of API calls)
197
-
198
- Version 0.1.0
199
- * Enhancements
200
- * Cleaned up unit tests for WSDL generator. Won't bother for SOAP ComplexType for now as I'm not needing this and it looks like Savon 3 will create example requests anyway
201
- * Put SOAP Basic Auth in Example
202
- * Added template handling for REST handler
203
-
204
- Version 0.0.89
205
- * Enhancements
206
- * Move more functionality out of soaspec exe and into WsdlGenerator. Started unit tests for it
207
-
208
- Version 0.0.88
209
- * Bug Fix
210
- * Corrected '_format' variable name that was breaking failing to find rest element
211
-
212
- Version 0.0.87
213
- * Bug Fix
214
- * Fixed incorrect logging for when 'debug_oauth' is off
215
-
216
- Version 0.0.86
217
- * Enhancements
218
- * 'debug_oauth' attribute used to toggle showing params used in retrieving access token
219
-
220
- Version 0.0.85
221
- * Enhancements
222
- * Interpret XML and JSON better so that JSON with XML in it's tags is catered for
223
-
224
- Version 0.0.84
225
- * Enhancements
226
- * 'strip_namespaces' defined in exchange handlers not globally which makes more sense
227
- * Created 'to_hash' method for Exchange that returns a Hash of XML or JSON response (primarily for REST)
228
-
229
- Version 0.0.83
230
- * Enhancements
231
- * Handle BOM or other characters that could be at start of xml of json response string
232
-
233
- Version 0.0.82
234
- * Enhancements
235
- * Fixed namespace handling for REST
236
-
237
- Version 0.0.81
238
- * Enhancements
239
- * SoapHandler - define exchange method for each SOAP operation. See `one_off_spec` for example
240
-
241
- Version 0.0.80
242
- * Enhancements
243
- * `values_from_path` method on `RestHandler` to easily extract multiple values for an xpath or json path
244
- * Bug fix
245
- * Support response that has white space surrounding message
246
-
247
- Version 0.0.79
248
- * Enhancements
249
- * `values_from_path` method on `SoapHandler` to easily extract multiple values for an xpath
250
- * If `id` is specified on associated factory, FactoryBot will populate the primary factory with that id. See `rest/factory_spec` for eg
251
-
252
- Version 0.0.78
253
- * Enhancements
254
- * Use 'thor' for `soaspec generate`, allowing less prompt and more options through command line. Added tests for it
255
-
256
- Version 0.0.77
257
- * Enhancements
258
- * Use 'thor' for soaspec-init binary changing it to be `soaspec init`. Will update `soaspec-generate` in next version
259
- * Put pause of 1/2 a second for each API retry. Often retry is too quick otherwise
260
-
261
- Version 0.0.76
262
- * Bug fix
263
- * Fixed BLZService scenario on soaspec-virtual-server
264
- * Fixed return value for retry_for_success failure
265
- * Enhancements
266
- * Added method to indicate a factory create should actually return a failure status
267
-
268
- Version 0.0.75
269
- * Enhancements
270
- * For Factory created methods, set retry_for_success to true. Allow for this to be set at Exchange class level
271
-
272
- Version 0.0.74
273
- * Enhancements
274
- * RestHandler, enable api username to be set upon initialisation
275
-
276
- Version 0.0.73
277
- * Enhancements
278
- * Added 'default_handler' method with which define an exchange_handler to be created when an exchange is initialized
279
- * Refactoring
280
- * Use `@exchange_handler` instead of `@api_class` which is more consistent
281
-
282
- Version 0.0.72
283
- * Enhancements
284
- * Add ability to convert XML response to lower case for simpler xpath searching
285
-
286
- Version 0.0.71
287
- * Bug fix
288
- * Got exe 'soaspec-virtual-server' working
289
-
290
- Version 0.0.70
291
- * Enhancements
292
- * Added api_username method to REST handler to change user for an API during runtime
293
-
294
- Version 0.0.69
295
- * Enhancements
296
- * Calculate base_url ERB at time of handler's first request (Rather than when initialised).
297
- - Important for where base url uses ERB and so does oauth whose user may change
298
- * Demonstrate using oauth via spec
299
- * Demonstrate using basic auth via spec
300
-
301
- Version 0.0.68
302
- * Enhancements
303
- * Use ERB to calculate base_url for dynamic bases
304
-
305
- Version 0.0.67
306
- * Enhancements
307
- * Handle scenario where Request key is unconventional and not PascalCase key snakecase convert would break it
308
- - if first character of key is captial, PascalCase conversion is ignored
309
-
310
- Version 0.0.66
311
- * Enhancements
312
- * Added method to convert REST request keys to 'PascalCase' if 'pascal_keys' is set to true
313
- * This also converts paths obtaining elements to 'PascalCase' if they're simple and have no starting '//' or '$..'
314
-
315
- Version 0.0.65
316
- * Enhancements
317
- * Added ability to set 'suburl' and 'method' in Exchange accessor. Will be used in FactoryBot later
318
-
319
- Version 0.0.64
320
- * Enhancements
321
- * Got FactoryBot working for RestHandler. See specs for example
322
- * Add element? method to exchange to make it easier to check element is at path
323
- * Define 'element_name?' created when element is defined on ExchangeHandler
324
-
325
- Version 0.0.63
326
- * Enhancements
327
- * Interpret ERB for oauth credentials within oauth response. Needed for when params like 'username' can change in runtime
328
-
329
- Version 0.0.62
330
- * Enhancements
331
- * Use q parameter to simply to query parameters on REST requests
332
-
333
- Version 0.0.61
334
- * Enhancements
335
- * Retrieving oauth response try 3 times (to bypass intermittent errors)
336
-
337
- Version 0.0.60
338
- * Enhancements
339
- * Allow for factory_bot with automatic setting of missing setter methods
340
-
341
- Version 0.0.59
342
- * Enhancements
343
- * Perform ERB in headers to make using access_token using 'headers' possible
344
- * Try better way of testing `soaspec-init`.
345
-
346
- Version 0.0.58
347
- * Enhancements
348
- * Add method to set parts of the request body through `exchange[key]= 'value'`
349
- * Added example of Cucumber feature demonstrating this
350
-
351
- Version 0.0.56
352
- * Bug fix
353
- * Handle creating of traffic.log file within lib properly
354
-
355
- Version 0.0.55
356
- * Enhancements
357
- * Made `soaspec-virtual-server` exe to handle self served test server. Will be used in wiki tutorial
358
-
359
- Version 0.0.54
360
- * Enhancements
361
- * Make 'headers' accessor for setting headers on RestHandler easier
362
-
363
- Version 0.0.53
364
- * Enhancements
365
- * Make attribute possible for REST methods as well (as they can use XML too)
366
- * For non XML, non JSON responses, handle with regex or key for a Hash
367
-
368
- Version 0.0.52
369
- * Enhancements
370
- * Now have 'attribute' accessor making it easy to access an attribute from a response
371
-
372
- Version 0.0.51
373
- * Enhancements
374
- * Allow for 'default_hash=' method to be used in RestHandler. See 'many_calls_one_method_spec' for example
375
- * Got 'element' accessor working correctly (See soap/hash_spec.rb + 'blz_service' for example)
376
-
377
- Version 0.0.50
378
- * Enhancements
379
- * Able to use ERB in oauth parameters and extract oauth hash with 'oauth_response' method defined by 'oauth_file'
380
-
381
- Version 0.0.47
382
- * Bug Fix
383
- * Using 'Strip namespace' handle both namespace or not dependent if used
384
-
385
- Version 0.0.47
386
- * Enhancements
387
- * 'success scenarios' shared eg and 'retry_for_success' exchange method's status codes include 200..299, not just 200.
388
-
389
- Version 0.0.46
390
- * Enhancements
391
- * 'include_key?' method use 'value_from_path'. Iterating through Hashes with 'include_key?' wouldn't work as expected with some JSON bodies with my current implementation
392
-
393
- Version 0.0.45
394
- * Enhancements
395
- * No need to use 'name' when creating SoapHandler and RestHandler. Default is ClassName
396
-
397
- Version 0.0.44
398
- * Enhancements
399
- * Test Server log to logs/test_server.log
400
- * Simplify ExchangeHandler storing and retrieving values (see soap/hash_spec.rb)
401
- * Make setting SoapHandler operation and other params possible through object instantiation. Less code needed
402
-
403
- Version 0.0.43
404
- * Bug fix
405
- * Remove Environment namespace from 'soaspec-generate'
406
- * Enhancements
407
- * Convenience methods for REST calls in which you can call something like 'ClassInheritingRestHandler.get(params)' See 'spec/soaspec/rest/one_off_spec.rb' for details
408
-
409
- Version 0.0.42
410
- * Enhancements
411
- * Set Soaspec.api_handler work class is created. No need to call '.to_s' method
412
-
413
- Version 0.0.41
414
- * Bug fix
415
- * soaspec-generate not designed to work with virtual service. Rakefile not try to set that up
416
-
417
- Version 0.0.40
418
- * Enhancements
419
- * soaspec-generate now handle a wsdl without parameters in the operation and rather look up input element type
420
- * test_server virtual service now handle scenario where bank is not found and test made for that
421
-
422
- Version 0.0.39
423
- * Spec
424
- * Create task to use soaspec-init to create test structure and test it.
425
- * Enhancements
426
- * Take away need to use Environment namespace
427
- * Added response headers to REST response log
428
- * Now using virtual Web Service for SOAP
429
-
430
- Version 0.0.38
431
- * Bug fix
432
- * Fixed error in soaspec-generate. TODO: Test this in CI
433
-
434
- Version 0.0.37 / 2018-3-16
435
- * Enhancements
436
- * Made retry_for_success method to keep making request until 200 status code if set on exchange
437
- * If '$' not included for json_path, by default a '$..' is added for convenience
438
-
439
- Version 0.0.36 / 2018-3-15
440
- * Bug fix
441
- * Make test name log in correct place
442
- * Enhancements
443
- * Made accessor 'mandatory_json_values' to make it easier to share mandatory json path - value pairs
444
- * Created 'store' method for handler through which one can store a value and use it later on it in the same context
445
- * Deprecated
446
- * Removed old 'mandatory_elements', 'mandatory_xpath_values' overridden way of handling data for favor of new way of it setting 'expected_mandatory_elements'
447
-
448
- Version 0.0.35 / 2018-3-13
449
- * Enhancements
450
- * Handle array of JSON hashes starting with '['
451
- * Handle patch and put methods with data for REST
452
-
453
- Version 0.0.34 / 2018-3-12
454
- * Enhancements
455
- * Add oauth2 and oauth2_file methods to make it easy to load oauth2 parameters. Still a work in progress to handle all oauth2 variations
456
-
457
- Version 0.0.33 / 2018-3-9
458
- * Enhancements
459
- * Use 'jsonpath' instead of dig to check JSON responses. Much better for finding complex paths
460
-
461
- Version 0.0.32 / 2018-3-9
462
- * Enhancements
463
- * Made :body key in hash that can be used to use JSON.generate for a payload when using rest_handler exchanges
464
-
465
- Version 0.0.31 / 2018-3-8
466
- * Enhancements
467
- * Compacted unit tests for exchange handler
468
- * Implemented include_key? and find via xpath for REST handler. See specs
469
-
470
- Version 0.0.30 / 2018-3-6
471
- * Bug fix
472
- * Made generated class file name in soaspec-generate snakecase (was CamelCase)
473
-
474
- Version 0.0.29 / 2018-3-6
475
- * Refactorings
476
- * Base 'test' class from 'Tester' to 'ExhangeHandler'
477
- * Made default Soap Handler class 'SoapHandler' and making use of 'BasicSoapHandler' deprecated
478
-
479
- Version 0.0.28 / 2018-3-6
480
- * Enhancements
481
- * Added not_found matcher and used in spec example
482
- * Only call request upon first need of an Exchange response. This means test request is made as part of 'it' rather than in describe
483
-
484
- Version 0.0.27 / 2018-3-5
485
- * Bug fix
486
- * Fixed log file not present error
487
- * Updated exe binaries to use latest format
488
-
489
- Version 0.0.26 / 2018-3-5
490
- * Refactorings
491
- * Using methods to define mandatory_elements, mandatory_xpath_values, root_attributes, base_url. Please see specs. This is shorter to type and clearer
492
-
493
- Version 0.0.25 / 2018-2-25
494
- * Enhancements
495
- * Updated rest_handler to convert JSON and XML into Hash and use it in 'contain_value'. This still needs work.
496
- * Showed example of workflow using 'pet' url
497
-
498
- Version 0.0.24 / 2018-2-25
499
- * Enhancements
500
- * Added to soaspec-generate more types when creating YAML with data (int, boolean, double and custom enumeration).
501
- * Binaries use common module (exe-helper) to reduce repeatability
502
- * TODO: soaspec-generate read xsd's mentioned to import in WSDL schema
503
-
504
- Version 0.0.23 / 2018-2-23
505
- * Enhancements
506
- * Created RestHandler class (Very messy and ugly still) to handle REST requests using style used for SOAP using Rest Client resource
507
-
508
- Version 0.0.22 / 2018-2-15
509
- * Enhancements
510
- * Created new 'include_in_body' matcher to find value anywhere in response body (which could be a substring of an element)
511
-
512
- Version 0.0.21 / 2018-1-29
513
- * Enhancements
514
- * Added soaspec-generate - still in POC mode to generate files from a WSDL.
515
- * Added test_wsdl to start at validating xml according to WSDL. Still needs polishing
516
-
517
- Version 0.0.20 / 2018-1-26
518
- * Enhancements
519
- * Added ability to strip namespaces 'Soaspec::Environment.strip_namespaces = true'. See spec for example
520
- * Fixes
521
- * Made custom error and used it to make 'have_element_at_xpath' work when negated
522
-
523
- Version 0.0.19 / 2018-1-25
524
- * Enhancements
525
- * Added own shared examples to init script and to in built specs
526
-
527
- Version 0.0.18 / 2018-1-25
528
- * Fixes
529
- * Updated 'soaspec-init' so that it works again.
530
- * Enhancements
531
- * Added example showing representing data for request in YAML
532
-
533
- Version 0.0.17 / 2018-1-25
534
- * Fixes
535
- * Updated hash search so that it handles Array
536
-
537
- Version 0.0.16 / 2018-1-23
538
- * Fixes
539
- * Corrected logic of auto convert to hash. Previous version did not handle test specific values correctly
540
-
541
- Version 0.0.15 / 2018-1-23
542
- * Fixes
543
- * Updated code to convert string key in Savon request to key automatically by default before passing to Savon. This saves
544
- the user doing the conversion themselves.
545
-
546
- Version 0.0.14 / 2018-1-23
547
- * Fixes
548
- * Updated 'xml_to_yaml_file' exe to clean up YAML more. No more array for Hash value. Indenting needs work though.
549
- Now it's more like something you can read and pass into Savon request.
550
-
551
- Version 0.0.13 / 2018-1-23
552
- * Enhancements
553
- * Executable to create xml file from yaml
554
-
555
- Version 0.0.12 / 2018/1-22
556
- * Enhancements
557
- * Example name added to log file
558
-
559
- Version 0.0.10 / 2018-1-21
560
- * Enhancements
561
- * Added [] method to perform xpath assertion
562
- * Using Savon xpath. No need to explicitly provide namespace for xpath
563
-
564
- Version 0.0.9 / 2018-1-20
565
- * Refactoring
566
- * class_options -> savon_options - More specific
567
- * default_operation -> operation - Not default anymore so better not in name
568
- * Enhancements
569
- * Made mandatory_xpath_values method to add to 'success scenarios' shared example
570
-
571
- Version 0.0.8 / 2018-1-19
572
- * Enhancements
573
- * Added root_attributes method to add attribute to the root class
574
-
575
- Version 0.0.7 / 2018-1-19
576
- * Enhancements
577
- * Added contain_key matcher
1
+ Version 0.2.25
2
+ * Enhancement
3
+ * Started running yard-doctest to check yard examples are correct
4
+ * Make it easy to inherit urls for subclasses of handlers through 'parent_url'
5
+ * `soaspec generate`
6
+ * Run on random port as it only makes sense it context of where it runs
7
+ * Add support for basic_auth
8
+ * `soaspec cucumber` create initial Gemfile and support/env if not present for getting started quickly
9
+ * Bug Fix
10
+ * Fixed issue with turning off log part way through test suite not turning off RestClient's logs
11
+
12
+ Version 0.2.24
13
+ * Bug Fix
14
+ * Be explicit about where shared_examples_for is from (RSpec) as it can cause loading issues
15
+
16
+ Version 0.2.23
17
+ * Enhancement
18
+ * Interpreter handles XML Doc
19
+ * Get document_type_for complex element working. Hopefully should be able to handle WSDL with large response now
20
+
21
+ Version 0.2.22
22
+ * Bug Fix
23
+ * Allow negated version of 'be_successful' to work
24
+ * Fix `Exchange.retry_count` so that it retries after first try the correct number of times
25
+ * Enhancement
26
+ * Make 'value_from_path' and 'values_from_path' methods accessible from 'response' object
27
+ * Get extracting text via RegEx actually working
28
+
29
+ Version 0.2.21
30
+ * Enhancement
31
+ * Enable deprecation warnings to be removed so that they're not annoying with `Soaspec.log_warnings`
32
+
33
+ Version 0.2.20
34
+ * Enhancement
35
+ * 'soaspec pry' command to open pry, loading test API classes
36
+
37
+ Version 0.2.19
38
+ * Enhancement
39
+ * Create 'soaspec generate' (without wsdl) as a way to create an ExchangeHandler from a Web Page
40
+
41
+ Version 0.2.18
42
+ * Enhancement
43
+ * Hash of body returned via 'to_hash' can be accessed through Symbol or String
44
+
45
+ Version 0.2.17
46
+ * Bug Fix
47
+ * Correct Output where does not show the conversion happening by JSONPath and PascalCase conversion
48
+
49
+ Version 0.2.16
50
+ * Enhancement
51
+ * Move debug oauth into OAuth2 class
52
+
53
+ Version 0.2.14
54
+ * Bug Fix
55
+ * Remove default log file being created before it is changed to a custom location
56
+
57
+ Version 0.2.13
58
+ * Enhancements
59
+ * Allow terminal logging color to be changed through a `terminal_color` attribute
60
+
61
+ Version 0.2.12
62
+ * Enhancements
63
+ * Make it easier to set 'traffic_file' location with `Soaspec::SpecLogger.traffic_file = ''`
64
+
65
+ Version 0.2.11
66
+ * Bug Fix
67
+ * Cache 'Soaspec::OAuth2.instance_url' so Access token server not called everytime it's needed
68
+
69
+ Version 0.2.10
70
+ * Enhancements
71
+ * Added 'soaspec/demo' to be required to simplify demoing
72
+ * Bug Fix
73
+ * Logging wasn't handling Rest log properly
74
+
75
+ Version 0.2.9
76
+ * Enhancements
77
+ * More documentation in README.md
78
+ * Started breaking up massive RestHandler more
79
+ * Allow one output logs to STDOUT through Soaspec::SpecLogger.output_to_terminal = true
80
+
81
+ Version 0.2.8
82
+ * Bug Fix
83
+ * RSpec-its dependency produces a conflict. Remove specific version reference
84
+
85
+ Version 0.2.7
86
+ * Bug Fix
87
+ * Fix log issue that was failing in Windows
88
+
89
+ Version 0.2.6
90
+ * Enhancements
91
+ * New log file created with time stamp each time tests are run
92
+
93
+ Version 0.2.5
94
+ * Bug fix
95
+ * Error wasn't throw if checking for element with empty response
96
+ * Default hash set on Exchange without example overriding value not setting request body
97
+
98
+ Version 0.2.4
99
+ * Enhancements
100
+ * Enable block to be used when creating exchange with Handler.exchange
101
+
102
+ Version 0.2.3
103
+ * Enhancements
104
+ * Exchange.until itself method returns itself making it easier to reuse last result in assertions
105
+ * Added parameters to Exchange.until so that timeout, message and interval can be specified
106
+ * Soaspec cucumber exe to add generic steps to step_definitions folder
107
+
108
+ Version 0.2.2
109
+ * Enhancements
110
+ * Make accessing test_values from template using indifferent access
111
+
112
+ Version 0.2.1
113
+ * Enhancements
114
+ * Make method to access 'client_id' within a class after specifying 'oauth2_file' to remove unnecessarily loading file twice
115
+
116
+ Version 0.2.0
117
+ * Exception handling
118
+ * Raise meaningful exception if REST header value passed is null
119
+ * Enhancements
120
+ * `soaspec add` exe to create basic 'rest' or 'soap' service
121
+ * Add another matcher to check response is successful
122
+ * Default hash and template_name can now be defined within a class rather than just at an instance of it
123
+ * Stubs making it clearer what parameters are when looking at code from RubyMine
124
+ * Basic auth file method on RestHandler for clearer defining of basic auth
125
+ * Handle ERB in 'base_url' method
126
+
127
+ Version 0.1.18
128
+ * Enhancements
129
+ * Define 'exchange' method on response object so original exchange can be accessed
130
+ * Make simply approach for setting body of request with just a string passed `ExchangeHandler.post(message_body)` where message_body is not
131
+ a `Hash` but a `String`
132
+
133
+ Version 0.1.17
134
+ * Enhancements
135
+ * Added Wait class to easily wait for an expected condition to be true, either using global Soaspec::Wait or `exchange.until { true }`
136
+ See spec/unit/wait_spec for example
137
+ * Made shorter way to `get` a REST url with `RestHandler.get 'id'` setting the suburl to 'id' automatically
138
+
139
+ Version 0.1.16
140
+ * Bug fix
141
+ * Retry was not working for OAuth access_token
142
+
143
+ Version 0.1.15
144
+ * Enhancements
145
+ * Added more unit test coverage and a few more comments
146
+
147
+ Version 0.1.14
148
+ * Enhancements
149
+ * Got `rest` soaspec new working
150
+
151
+ Version 0.1.13
152
+ * Enhancements
153
+ * Cleaned up comments (mainly OAuth2 related)
154
+ * Cleaned up REST handler code, adding more comments on usage
155
+ * Added 'soaspec/cucumber/generic_steps' to simplify reusing code and also demonstrate how gem can be used
156
+
157
+ Version 0.1.12
158
+ * Enhancements
159
+ * Add 'refresh_token' attribute to Soaspec::OAuth2 class so that token can be retrieved once and then stored
160
+
161
+ Version 0.1.11
162
+ * Enhancements
163
+ * OAuth2 class can be initialized with strings as keys
164
+ * Global attribute, 'Soaspec::OAuth2.token_url' for setting common value
165
+
166
+ Version 0.1.10
167
+ * Enhancements
168
+ * Rename default template folder from to 'template' to 'templates'
169
+ * Use TemplateReader to simplify and add error handling to extracting templates
170
+ * Got convenience Rest Methods able to handle taking in template_name
171
+ * Started making a 'request' method to access request of API actually sent
172
+
173
+ Version 0.1.9
174
+ * Enhancements
175
+ * Finally move `soaspec-virtual-server` into same binary as `soaspec` utilising Thor
176
+
177
+ Version 0.1.8
178
+ * Bug fix
179
+ * Could not see OAuth parameters sent in logs when setting oauth debugging to true
180
+
181
+ Version 0.1.7
182
+ * Enhancements
183
+ * Include access token header automatically if 'authorization' is not set. Turn off with `Soaspec.auto_oauth = false`
184
+
185
+ Version 0.1.6
186
+ * Enhancements
187
+ * Bind localhost to 0.0.0.0 so service is accessible outside localhost
188
+
189
+ Version 0.1.5
190
+ * Enhancements
191
+ * Package spec changes status after a post is made. Help to illustrate scenario where status changes
192
+ * Record last exchange made for debugging purposes in 'last_exchange'
193
+
194
+ Version 0.1.4
195
+ * Enhancements
196
+ * create_file method create folders automatically if necessary
197
+ * Package spec to help learn testing for items in a list
198
+ * Added docs for soaspec-virtual-server
199
+
200
+ Version 0.1.3
201
+ * Enhancements
202
+ * Ability to set template folder
203
+ * Json Path handle multiple paths separated by commas
204
+
205
+ Version 0.1.1
206
+ * Enhancements
207
+ * Added ability to turn off logs (helpful if making a lot of API calls)
208
+
209
+ Version 0.1.0
210
+ * Enhancements
211
+ * Cleaned up unit tests for WSDL generator. Won't bother for SOAP ComplexType for now as I'm not needing this and it looks like Savon 3 will create example requests anyway
212
+ * Put SOAP Basic Auth in Example
213
+ * Added template handling for REST handler
214
+
215
+ Version 0.0.89
216
+ * Enhancements
217
+ * Move more functionality out of soaspec exe and into WsdlGenerator. Started unit tests for it
218
+
219
+ Version 0.0.88
220
+ * Bug Fix
221
+ * Corrected '_format' variable name that was breaking failing to find rest element
222
+
223
+ Version 0.0.87
224
+ * Bug Fix
225
+ * Fixed incorrect logging for when 'debug_oauth' is off
226
+
227
+ Version 0.0.86
228
+ * Enhancements
229
+ * 'debug_oauth' attribute used to toggle showing params used in retrieving access token
230
+
231
+ Version 0.0.85
232
+ * Enhancements
233
+ * Interpret XML and JSON better so that JSON with XML in it's tags is catered for
234
+
235
+ Version 0.0.84
236
+ * Enhancements
237
+ * 'strip_namespaces' defined in exchange handlers not globally which makes more sense
238
+ * Created 'to_hash' method for Exchange that returns a Hash of XML or JSON response (primarily for REST)
239
+
240
+ Version 0.0.83
241
+ * Enhancements
242
+ * Handle BOM or other characters that could be at start of xml of json response string
243
+
244
+ Version 0.0.82
245
+ * Enhancements
246
+ * Fixed namespace handling for REST
247
+
248
+ Version 0.0.81
249
+ * Enhancements
250
+ * SoapHandler - define exchange method for each SOAP operation. See `one_off_spec` for example
251
+
252
+ Version 0.0.80
253
+ * Enhancements
254
+ * `values_from_path` method on `RestHandler` to easily extract multiple values for an xpath or json path
255
+ * Bug fix
256
+ * Support response that has white space surrounding message
257
+
258
+ Version 0.0.79
259
+ * Enhancements
260
+ * `values_from_path` method on `SoapHandler` to easily extract multiple values for an xpath
261
+ * If `id` is specified on associated factory, FactoryBot will populate the primary factory with that id. See `rest/factory_spec` for eg
262
+
263
+ Version 0.0.78
264
+ * Enhancements
265
+ * Use 'thor' for `soaspec generate`, allowing less prompt and more options through command line. Added tests for it
266
+
267
+ Version 0.0.77
268
+ * Enhancements
269
+ * Use 'thor' for soaspec-init binary changing it to be `soaspec init`. Will update `soaspec-generate` in next version
270
+ * Put pause of 1/2 a second for each API retry. Often retry is too quick otherwise
271
+
272
+ Version 0.0.76
273
+ * Bug fix
274
+ * Fixed BLZService scenario on soaspec-virtual-server
275
+ * Fixed return value for retry_for_success failure
276
+ * Enhancements
277
+ * Added method to indicate a factory create should actually return a failure status
278
+
279
+ Version 0.0.75
280
+ * Enhancements
281
+ * For Factory created methods, set retry_for_success to true. Allow for this to be set at Exchange class level
282
+
283
+ Version 0.0.74
284
+ * Enhancements
285
+ * RestHandler, enable api username to be set upon initialisation
286
+
287
+ Version 0.0.73
288
+ * Enhancements
289
+ * Added 'default_handler' method with which define an exchange_handler to be created when an exchange is initialized
290
+ * Refactoring
291
+ * Use `@exchange_handler` instead of `@api_class` which is more consistent
292
+
293
+ Version 0.0.72
294
+ * Enhancements
295
+ * Add ability to convert XML response to lower case for simpler xpath searching
296
+
297
+ Version 0.0.71
298
+ * Bug fix
299
+ * Got exe 'soaspec-virtual-server' working
300
+
301
+ Version 0.0.70
302
+ * Enhancements
303
+ * Added api_username method to REST handler to change user for an API during runtime
304
+
305
+ Version 0.0.69
306
+ * Enhancements
307
+ * Calculate base_url ERB at time of handler's first request (Rather than when initialised).
308
+ - Important for where base url uses ERB and so does oauth whose user may change
309
+ * Demonstrate using oauth via spec
310
+ * Demonstrate using basic auth via spec
311
+
312
+ Version 0.0.68
313
+ * Enhancements
314
+ * Use ERB to calculate base_url for dynamic bases
315
+
316
+ Version 0.0.67
317
+ * Enhancements
318
+ * Handle scenario where Request key is unconventional and not PascalCase key snakecase convert would break it
319
+ - if first character of key is captial, PascalCase conversion is ignored
320
+
321
+ Version 0.0.66
322
+ * Enhancements
323
+ * Added method to convert REST request keys to 'PascalCase' if 'pascal_keys' is set to true
324
+ * This also converts paths obtaining elements to 'PascalCase' if they're simple and have no starting '//' or '$..'
325
+
326
+ Version 0.0.65
327
+ * Enhancements
328
+ * Added ability to set 'suburl' and 'method' in Exchange accessor. Will be used in FactoryBot later
329
+
330
+ Version 0.0.64
331
+ * Enhancements
332
+ * Got FactoryBot working for RestHandler. See specs for example
333
+ * Add element? method to exchange to make it easier to check element is at path
334
+ * Define 'element_name?' created when element is defined on ExchangeHandler
335
+
336
+ Version 0.0.63
337
+ * Enhancements
338
+ * Interpret ERB for oauth credentials within oauth response. Needed for when params like 'username' can change in runtime
339
+
340
+ Version 0.0.62
341
+ * Enhancements
342
+ * Use q parameter to simply to query parameters on REST requests
343
+
344
+ Version 0.0.61
345
+ * Enhancements
346
+ * Retrieving oauth response try 3 times (to bypass intermittent errors)
347
+
348
+ Version 0.0.60
349
+ * Enhancements
350
+ * Allow for factory_bot with automatic setting of missing setter methods
351
+
352
+ Version 0.0.59
353
+ * Enhancements
354
+ * Perform ERB in headers to make using access_token using 'headers' possible
355
+ * Try better way of testing `soaspec-init`.
356
+
357
+ Version 0.0.58
358
+ * Enhancements
359
+ * Add method to set parts of the request body through `exchange[key]= 'value'`
360
+ * Added example of Cucumber feature demonstrating this
361
+
362
+ Version 0.0.56
363
+ * Bug fix
364
+ * Handle creating of traffic.log file within lib properly
365
+
366
+ Version 0.0.55
367
+ * Enhancements
368
+ * Made `soaspec-virtual-server` exe to handle self served test server. Will be used in wiki tutorial
369
+
370
+ Version 0.0.54
371
+ * Enhancements
372
+ * Make 'headers' accessor for setting headers on RestHandler easier
373
+
374
+ Version 0.0.53
375
+ * Enhancements
376
+ * Make attribute possible for REST methods as well (as they can use XML too)
377
+ * For non XML, non JSON responses, handle with regex or key for a Hash
378
+
379
+ Version 0.0.52
380
+ * Enhancements
381
+ * Now have 'attribute' accessor making it easy to access an attribute from a response
382
+
383
+ Version 0.0.51
384
+ * Enhancements
385
+ * Allow for 'default_hash=' method to be used in RestHandler. See 'many_calls_one_method_spec' for example
386
+ * Got 'element' accessor working correctly (See soap/hash_spec.rb + 'blz_service' for example)
387
+
388
+ Version 0.0.50
389
+ * Enhancements
390
+ * Able to use ERB in oauth parameters and extract oauth hash with 'oauth_response' method defined by 'oauth_file'
391
+
392
+ Version 0.0.47
393
+ * Bug Fix
394
+ * Using 'Strip namespace' handle both namespace or not dependent if used
395
+
396
+ Version 0.0.47
397
+ * Enhancements
398
+ * 'success scenarios' shared eg and 'retry_for_success' exchange method's status codes include 200..299, not just 200.
399
+
400
+ Version 0.0.46
401
+ * Enhancements
402
+ * 'include_key?' method use 'value_from_path'. Iterating through Hashes with 'include_key?' wouldn't work as expected with some JSON bodies with my current implementation
403
+
404
+ Version 0.0.45
405
+ * Enhancements
406
+ * No need to use 'name' when creating SoapHandler and RestHandler. Default is ClassName
407
+
408
+ Version 0.0.44
409
+ * Enhancements
410
+ * Test Server log to logs/test_server.log
411
+ * Simplify ExchangeHandler storing and retrieving values (see soap/hash_spec.rb)
412
+ * Make setting SoapHandler operation and other params possible through object instantiation. Less code needed
413
+
414
+ Version 0.0.43
415
+ * Bug fix
416
+ * Remove Environment namespace from 'soaspec-generate'
417
+ * Enhancements
418
+ * Convenience methods for REST calls in which you can call something like 'ClassInheritingRestHandler.get(params)' See 'spec/soaspec/rest/one_off_spec.rb' for details
419
+
420
+ Version 0.0.42
421
+ * Enhancements
422
+ * Set Soaspec.api_handler work class is created. No need to call '.to_s' method
423
+
424
+ Version 0.0.41
425
+ * Bug fix
426
+ * soaspec-generate not designed to work with virtual service. Rakefile not try to set that up
427
+
428
+ Version 0.0.40
429
+ * Enhancements
430
+ * soaspec-generate now handle a wsdl without parameters in the operation and rather look up input element type
431
+ * test_server virtual service now handle scenario where bank is not found and test made for that
432
+
433
+ Version 0.0.39
434
+ * Spec
435
+ * Create task to use soaspec-init to create test structure and test it.
436
+ * Enhancements
437
+ * Take away need to use Environment namespace
438
+ * Added response headers to REST response log
439
+ * Now using virtual Web Service for SOAP
440
+
441
+ Version 0.0.38
442
+ * Bug fix
443
+ * Fixed error in soaspec-generate. TODO: Test this in CI
444
+
445
+ Version 0.0.37 / 2018-3-16
446
+ * Enhancements
447
+ * Made retry_for_success method to keep making request until 200 status code if set on exchange
448
+ * If '$' not included for json_path, by default a '$..' is added for convenience
449
+
450
+ Version 0.0.36 / 2018-3-15
451
+ * Bug fix
452
+ * Make test name log in correct place
453
+ * Enhancements
454
+ * Made accessor 'mandatory_json_values' to make it easier to share mandatory json path - value pairs
455
+ * Created 'store' method for handler through which one can store a value and use it later on it in the same context
456
+ * Deprecated
457
+ * Removed old 'mandatory_elements', 'mandatory_xpath_values' overridden way of handling data for favor of new way of it setting 'expected_mandatory_elements'
458
+
459
+ Version 0.0.35 / 2018-3-13
460
+ * Enhancements
461
+ * Handle array of JSON hashes starting with '['
462
+ * Handle patch and put methods with data for REST
463
+
464
+ Version 0.0.34 / 2018-3-12
465
+ * Enhancements
466
+ * Add oauth2 and oauth2_file methods to make it easy to load oauth2 parameters. Still a work in progress to handle all oauth2 variations
467
+
468
+ Version 0.0.33 / 2018-3-9
469
+ * Enhancements
470
+ * Use 'jsonpath' instead of dig to check JSON responses. Much better for finding complex paths
471
+
472
+ Version 0.0.32 / 2018-3-9
473
+ * Enhancements
474
+ * Made :body key in hash that can be used to use JSON.generate for a payload when using rest_handler exchanges
475
+
476
+ Version 0.0.31 / 2018-3-8
477
+ * Enhancements
478
+ * Compacted unit tests for exchange handler
479
+ * Implemented include_key? and find via xpath for REST handler. See specs
480
+
481
+ Version 0.0.30 / 2018-3-6
482
+ * Bug fix
483
+ * Made generated class file name in soaspec-generate snakecase (was CamelCase)
484
+
485
+ Version 0.0.29 / 2018-3-6
486
+ * Refactorings
487
+ * Base 'test' class from 'Tester' to 'ExhangeHandler'
488
+ * Made default Soap Handler class 'SoapHandler' and making use of 'BasicSoapHandler' deprecated
489
+
490
+ Version 0.0.28 / 2018-3-6
491
+ * Enhancements
492
+ * Added not_found matcher and used in spec example
493
+ * Only call request upon first need of an Exchange response. This means test request is made as part of 'it' rather than in describe
494
+
495
+ Version 0.0.27 / 2018-3-5
496
+ * Bug fix
497
+ * Fixed log file not present error
498
+ * Updated exe binaries to use latest format
499
+
500
+ Version 0.0.26 / 2018-3-5
501
+ * Refactorings
502
+ * Using methods to define mandatory_elements, mandatory_xpath_values, root_attributes, base_url. Please see specs. This is shorter to type and clearer
503
+
504
+ Version 0.0.25 / 2018-2-25
505
+ * Enhancements
506
+ * Updated rest_handler to convert JSON and XML into Hash and use it in 'contain_value'. This still needs work.
507
+ * Showed example of workflow using 'pet' url
508
+
509
+ Version 0.0.24 / 2018-2-25
510
+ * Enhancements
511
+ * Added to soaspec-generate more types when creating YAML with data (int, boolean, double and custom enumeration).
512
+ * Binaries use common module (exe-helper) to reduce repeatability
513
+ * TODO: soaspec-generate read xsd's mentioned to import in WSDL schema
514
+
515
+ Version 0.0.23 / 2018-2-23
516
+ * Enhancements
517
+ * Created RestHandler class (Very messy and ugly still) to handle REST requests using style used for SOAP using Rest Client resource
518
+
519
+ Version 0.0.22 / 2018-2-15
520
+ * Enhancements
521
+ * Created new 'include_in_body' matcher to find value anywhere in response body (which could be a substring of an element)
522
+
523
+ Version 0.0.21 / 2018-1-29
524
+ * Enhancements
525
+ * Added soaspec-generate - still in POC mode to generate files from a WSDL.
526
+ * Added test_wsdl to start at validating xml according to WSDL. Still needs polishing
527
+
528
+ Version 0.0.20 / 2018-1-26
529
+ * Enhancements
530
+ * Added ability to strip namespaces 'Soaspec::Environment.strip_namespaces = true'. See spec for example
531
+ * Fixes
532
+ * Made custom error and used it to make 'have_element_at_xpath' work when negated
533
+
534
+ Version 0.0.19 / 2018-1-25
535
+ * Enhancements
536
+ * Added own shared examples to init script and to in built specs
537
+
538
+ Version 0.0.18 / 2018-1-25
539
+ * Fixes
540
+ * Updated 'soaspec-init' so that it works again.
541
+ * Enhancements
542
+ * Added example showing representing data for request in YAML
543
+
544
+ Version 0.0.17 / 2018-1-25
545
+ * Fixes
546
+ * Updated hash search so that it handles Array
547
+
548
+ Version 0.0.16 / 2018-1-23
549
+ * Fixes
550
+ * Corrected logic of auto convert to hash. Previous version did not handle test specific values correctly
551
+
552
+ Version 0.0.15 / 2018-1-23
553
+ * Fixes
554
+ * Updated code to convert string key in Savon request to key automatically by default before passing to Savon. This saves
555
+ the user doing the conversion themselves.
556
+
557
+ Version 0.0.14 / 2018-1-23
558
+ * Fixes
559
+ * Updated 'xml_to_yaml_file' exe to clean up YAML more. No more array for Hash value. Indenting needs work though.
560
+ Now it's more like something you can read and pass into Savon request.
561
+
562
+ Version 0.0.13 / 2018-1-23
563
+ * Enhancements
564
+ * Executable to create xml file from yaml
565
+
566
+ Version 0.0.12 / 2018/1-22
567
+ * Enhancements
568
+ * Example name added to log file
569
+
570
+ Version 0.0.10 / 2018-1-21
571
+ * Enhancements
572
+ * Added [] method to perform xpath assertion
573
+ * Using Savon xpath. No need to explicitly provide namespace for xpath
574
+
575
+ Version 0.0.9 / 2018-1-20
576
+ * Refactoring
577
+ * class_options -> savon_options - More specific
578
+ * default_operation -> operation - Not default anymore so better not in name
579
+ * Enhancements
580
+ * Made mandatory_xpath_values method to add to 'success scenarios' shared example
581
+
582
+ Version 0.0.8 / 2018-1-19
583
+ * Enhancements
584
+ * Added root_attributes method to add attribute to the root class
585
+
586
+ Version 0.0.7 / 2018-1-19
587
+ * Enhancements
588
+ * Added contain_key matcher
578
589
  * mandatory_elements method created for SoapHandler - can be used to add tests to success scenarios (see example get_weather_web_service class for details)