mailgunner 2.2.1 → 2.2.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: c02531600fab1221d6d30e2d518c6f87aae0df1b
4
- data.tar.gz: a3f1cb1c7b9e662b7299736a58149c70f40ca8a6
3
+ metadata.gz: 7c67fa45a36b770cb9d3d29b970dfc281f00bc8d
4
+ data.tar.gz: 9640ba5d282f2438ebee99d011ad14f3578c62cd
5
5
  SHA512:
6
- metadata.gz: 79be4a3ad893f43b3591e5831d6a65ef153f54e30f98676aed742995f276d7c340b011262fd1e5241c4050db2be91a28d8d83fc41cea483e1d26521e876f672c
7
- data.tar.gz: cbffc63312385c670f2957ad6d3b069095ba64aaf53549703d905b9a071e6c4909c39cbfad568308e7392a78e76d20b5945c49b12d0c6fd2264dac6e7c504d38
6
+ metadata.gz: 6e7e43cd04b35336a3cc1ddfd6f74a63d7ed5e75e027e312a32b5c7619e71e35084cd6f366c8c71d9fd05d2243e2d34eac697fe1d4f11d106e3e8165583037a8
7
+ data.tar.gz: 2baeceef88a9b0b1d79ba5737f7afc9643611af1533ba5499f4c1cea4486db2ea9a0a0ceaf221b4ad22ae19a520c791be493a3adb4acf5b26214c2dcd53deeb8
data/README.md CHANGED
@@ -2,7 +2,7 @@ mailgunner
2
2
  ==========
3
3
 
4
4
 
5
- A Ruby wrapper for the [Mailgun API](http://documentation.mailgun.net/api_reference.html).
5
+ Ruby client for the [Mailgun API](http://documentation.mailgun.net/api_reference.html).
6
6
 
7
7
 
8
8
  Installation
data/lib/mailgunner.rb CHANGED
@@ -53,7 +53,7 @@ module Mailgunner
53
53
  end
54
54
 
55
55
  def send_mime(mail)
56
- to = ['to', Array(mail.to).join(',')]
56
+ to = ['to', Array(mail.destinations).join(',')]
57
57
 
58
58
  message = ['message', mail.encoded, {filename: 'message.mime'}]
59
59
 
data/mailgunner.gemspec CHANGED
@@ -1,18 +1,19 @@
1
1
  Gem::Specification.new do |s|
2
2
  s.name = 'mailgunner'
3
- s.version = '2.2.1'
3
+ s.version = '2.2.2'
4
4
  s.license = 'LGPL-3.0'
5
5
  s.platform = Gem::Platform::RUBY
6
6
  s.authors = ['Tim Craft']
7
7
  s.email = ['mail@timcraft.com']
8
8
  s.homepage = 'http://github.com/timcraft/mailgunner'
9
- s.description = 'A Ruby wrapper for the Mailgun API'
10
- s.summary = 'See description'
9
+ s.description = 'Ruby client for the Mailgun API'
10
+ s.summary = 'Ruby client for the Mailgun API'
11
11
  s.files = Dir.glob('{lib,spec}/**/*') + %w(LICENSE.txt README.md mailgunner.gemspec)
12
12
  s.required_ruby_version = '>= 1.9.3'
13
13
  s.add_development_dependency('rake', '~> 10.1')
14
14
  s.add_development_dependency('webmock', '~> 1.18')
15
15
  s.add_development_dependency('mail', '~> 2.5')
16
16
  s.add_development_dependency('actionmailer', '~> 4.0')
17
+ s.add_development_dependency('mocha', '~> 1.0')
17
18
  s.require_path = 'lib'
18
19
  end
@@ -1,5 +1,6 @@
1
1
  require 'minitest/autorun'
2
2
  require 'webmock/minitest'
3
+ require 'mocha/setup'
3
4
  require 'mailgunner'
4
5
  require 'json'
5
6
  require 'mail'
@@ -138,6 +139,19 @@ describe 'Mailgunner::Client' do
138
139
 
139
140
  @client.send_mime(@mail).must_equal(@json_response_object)
140
141
  end
142
+
143
+ it 'includes all recipients of the message' do
144
+ @mail.cc = 'carol@example.com'
145
+ @mail.bcc = 'dave@example.com'
146
+
147
+ stub_request(:post, "#@base_url/#@domain/messages.mime")
148
+
149
+ recipients = 'alice@example.com,carol@example.com,dave@example.com'
150
+
151
+ Net::HTTP::Post.any_instance.expects(:set_form).with(includes(['to', recipients]), 'multipart/form-data')
152
+
153
+ @client.send_mime(@mail)
154
+ end
141
155
  end
142
156
 
143
157
  describe 'delete_message method' do
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mailgunner
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.2.1
4
+ version: 2.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tim Craft
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-05-09 00:00:00.000000000 Z
11
+ date: 2016-01-20 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake
@@ -66,7 +66,21 @@ dependencies:
66
66
  - - "~>"
67
67
  - !ruby/object:Gem::Version
68
68
  version: '4.0'
69
- description: A Ruby wrapper for the Mailgun API
69
+ - !ruby/object:Gem::Dependency
70
+ name: mocha
71
+ requirement: !ruby/object:Gem::Requirement
72
+ requirements:
73
+ - - "~>"
74
+ - !ruby/object:Gem::Version
75
+ version: '1.0'
76
+ type: :development
77
+ prerelease: false
78
+ version_requirements: !ruby/object:Gem::Requirement
79
+ requirements:
80
+ - - "~>"
81
+ - !ruby/object:Gem::Version
82
+ version: '1.0'
83
+ description: Ruby client for the Mailgun API
70
84
  email:
71
85
  - mail@timcraft.com
72
86
  executables: []
@@ -104,5 +118,5 @@ rubyforge_project:
104
118
  rubygems_version: 2.2.2
105
119
  signing_key:
106
120
  specification_version: 4
107
- summary: See description
121
+ summary: Ruby client for the Mailgun API
108
122
  test_files: []