postmark 1.8.1 → 1.21.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (49) hide show
  1. checksums.yaml +5 -5
  2. data/.gitignore +2 -0
  3. data/.travis.yml +8 -5
  4. data/CHANGELOG.rdoc +86 -0
  5. data/CONTRIBUTING.md +18 -0
  6. data/Gemfile +6 -5
  7. data/LICENSE +1 -1
  8. data/README.md +34 -607
  9. data/RELEASE.md +12 -0
  10. data/VERSION +1 -1
  11. data/gemfiles/Gemfile.legacy +5 -4
  12. data/lib/postmark.rb +1 -18
  13. data/lib/postmark/account_api_client.rb +55 -1
  14. data/lib/postmark/api_client.rb +145 -17
  15. data/lib/postmark/bounce.rb +0 -4
  16. data/lib/postmark/client.rb +12 -4
  17. data/lib/postmark/error.rb +127 -0
  18. data/lib/postmark/handlers/mail.rb +10 -4
  19. data/lib/postmark/helpers/message_helper.rb +4 -0
  20. data/lib/postmark/http_client.rb +20 -32
  21. data/lib/postmark/mail_message_converter.rb +18 -5
  22. data/lib/postmark/message_extensions/mail.rb +83 -8
  23. data/lib/postmark/version.rb +1 -1
  24. data/postmark.gemspec +1 -1
  25. data/postmark.png +0 -0
  26. data/spec/integration/account_api_client_spec.rb +42 -10
  27. data/spec/integration/api_client_hashes_spec.rb +32 -49
  28. data/spec/integration/api_client_messages_spec.rb +33 -52
  29. data/spec/integration/api_client_resources_spec.rb +12 -44
  30. data/spec/integration/mail_delivery_method_spec.rb +21 -23
  31. data/spec/spec_helper.rb +4 -7
  32. data/spec/support/custom_matchers.rb +44 -0
  33. data/spec/support/shared_examples.rb +16 -16
  34. data/spec/unit/postmark/account_api_client_spec.rb +239 -45
  35. data/spec/unit/postmark/api_client_spec.rb +792 -406
  36. data/spec/unit/postmark/bounce_spec.rb +40 -62
  37. data/spec/unit/postmark/client_spec.rb +0 -6
  38. data/spec/unit/postmark/error_spec.rb +231 -0
  39. data/spec/unit/postmark/handlers/mail_spec.rb +59 -27
  40. data/spec/unit/postmark/helpers/hash_helper_spec.rb +5 -6
  41. data/spec/unit/postmark/helpers/message_helper_spec.rb +60 -11
  42. data/spec/unit/postmark/http_client_spec.rb +76 -61
  43. data/spec/unit/postmark/inbound_spec.rb +34 -34
  44. data/spec/unit/postmark/inflector_spec.rb +11 -13
  45. data/spec/unit/postmark/json_spec.rb +2 -2
  46. data/spec/unit/postmark/mail_message_converter_spec.rb +250 -81
  47. data/spec/unit/postmark/message_extensions/mail_spec.rb +249 -38
  48. data/spec/unit/postmark_spec.rb +37 -37
  49. metadata +41 -11
metadata CHANGED
@@ -1,19 +1,19 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: postmark
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.8.1
4
+ version: 1.21.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Petyo Ivanov
8
8
  - Ilya Sabanin
9
9
  - Artem Chistyakov
10
- autorequire:
10
+ autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2016-07-12 00:00:00.000000000 Z
13
+ date: 2020-12-03 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
- name: rake
16
+ name: json
17
17
  requirement: !ruby/object:Gem::Requirement
18
18
  requirements:
19
19
  - - ">="
@@ -27,13 +27,13 @@ dependencies:
27
27
  - !ruby/object:Gem::Version
28
28
  version: '0'
29
29
  - !ruby/object:Gem::Dependency
30
- name: json
30
+ name: mail
31
31
  requirement: !ruby/object:Gem::Requirement
32
32
  requirements:
33
33
  - - ">="
34
34
  - !ruby/object:Gem::Version
35
35
  version: '0'
36
- type: :runtime
36
+ type: :development
37
37
  prerelease: false
38
38
  version_requirements: !ruby/object:Gem::Requirement
39
39
  requirements:
@@ -41,7 +41,7 @@ dependencies:
41
41
  - !ruby/object:Gem::Version
42
42
  version: '0'
43
43
  - !ruby/object:Gem::Dependency
44
- name: mail
44
+ name: rake
45
45
  requirement: !ruby/object:Gem::Requirement
46
46
  requirements:
47
47
  - - ">="
@@ -69,9 +69,11 @@ files:
69
69
  - ".rspec"
70
70
  - ".travis.yml"
71
71
  - CHANGELOG.rdoc
72
+ - CONTRIBUTING.md
72
73
  - Gemfile
73
74
  - LICENSE
74
75
  - README.md
76
+ - RELEASE.md
75
77
  - Rakefile
76
78
  - VERSION
77
79
  - gemfiles/Gemfile.legacy
@@ -81,6 +83,7 @@ files:
81
83
  - lib/postmark/api_client.rb
82
84
  - lib/postmark/bounce.rb
83
85
  - lib/postmark/client.rb
86
+ - lib/postmark/error.rb
84
87
  - lib/postmark/handlers/mail.rb
85
88
  - lib/postmark/helpers/hash_helper.rb
86
89
  - lib/postmark/helpers/message_helper.rb
@@ -95,6 +98,7 @@ files:
95
98
  - lib/postmark/response_parsers/yajl.rb
96
99
  - lib/postmark/version.rb
97
100
  - postmark.gemspec
101
+ - postmark.png
98
102
  - spec/data/empty.gif
99
103
  - spec/integration/account_api_client_spec.rb
100
104
  - spec/integration/api_client_hashes_spec.rb
@@ -102,12 +106,14 @@ files:
102
106
  - spec/integration/api_client_resources_spec.rb
103
107
  - spec/integration/mail_delivery_method_spec.rb
104
108
  - spec/spec_helper.rb
109
+ - spec/support/custom_matchers.rb
105
110
  - spec/support/helpers.rb
106
111
  - spec/support/shared_examples.rb
107
112
  - spec/unit/postmark/account_api_client_spec.rb
108
113
  - spec/unit/postmark/api_client_spec.rb
109
114
  - spec/unit/postmark/bounce_spec.rb
110
115
  - spec/unit/postmark/client_spec.rb
116
+ - spec/unit/postmark/error_spec.rb
111
117
  - spec/unit/postmark/handlers/mail_spec.rb
112
118
  - spec/unit/postmark/helpers/hash_helper_spec.rb
113
119
  - spec/unit/postmark/helpers/message_helper_spec.rb
@@ -141,9 +147,33 @@ required_rubygems_version: !ruby/object:Gem::Requirement
141
147
  - !ruby/object:Gem::Version
142
148
  version: 1.3.7
143
149
  requirements: []
144
- rubyforge_project:
145
- rubygems_version: 2.4.5.1
146
- signing_key:
150
+ rubygems_version: 3.1.4
151
+ signing_key:
147
152
  specification_version: 4
148
153
  summary: Official Postmark API wrapper.
149
- test_files: []
154
+ test_files:
155
+ - spec/data/empty.gif
156
+ - spec/integration/account_api_client_spec.rb
157
+ - spec/integration/api_client_hashes_spec.rb
158
+ - spec/integration/api_client_messages_spec.rb
159
+ - spec/integration/api_client_resources_spec.rb
160
+ - spec/integration/mail_delivery_method_spec.rb
161
+ - spec/spec_helper.rb
162
+ - spec/support/custom_matchers.rb
163
+ - spec/support/helpers.rb
164
+ - spec/support/shared_examples.rb
165
+ - spec/unit/postmark/account_api_client_spec.rb
166
+ - spec/unit/postmark/api_client_spec.rb
167
+ - spec/unit/postmark/bounce_spec.rb
168
+ - spec/unit/postmark/client_spec.rb
169
+ - spec/unit/postmark/error_spec.rb
170
+ - spec/unit/postmark/handlers/mail_spec.rb
171
+ - spec/unit/postmark/helpers/hash_helper_spec.rb
172
+ - spec/unit/postmark/helpers/message_helper_spec.rb
173
+ - spec/unit/postmark/http_client_spec.rb
174
+ - spec/unit/postmark/inbound_spec.rb
175
+ - spec/unit/postmark/inflector_spec.rb
176
+ - spec/unit/postmark/json_spec.rb
177
+ - spec/unit/postmark/mail_message_converter_spec.rb
178
+ - spec/unit/postmark/message_extensions/mail_spec.rb
179
+ - spec/unit/postmark_spec.rb