jpmobile 5.2.5 → 6.0.0.beta

Sign up to get free protection for your applications and to get access to all the features.
Files changed (40) hide show
  1. checksums.yaml +4 -4
  2. data/.circleci/config.yml +1 -1
  3. data/.ruby-version +1 -1
  4. data/Gemfile.lock +111 -93
  5. data/jpmobile.gemspec +1 -1
  6. data/lib/jpmobile/hook_action_view.rb +4 -10
  7. data/lib/jpmobile/rails.rb +2 -0
  8. data/lib/jpmobile/resolver.rb +2 -36
  9. data/lib/jpmobile/version.rb +1 -1
  10. data/lib/tasks/jpmobile_tasks.rake +2 -2
  11. data/spec/unit/receive_mail_spec.rb +9 -9
  12. data/test/rails/overrides/Gemfile.jpmobile +6 -1
  13. data/test/rails/overrides/app/controllers/mobile_spec_controller.rb +1 -1
  14. data/test/rails/overrides/app/mailboxes/application_mailbox.rb +3 -0
  15. data/test/rails/overrides/app/mailboxes/mobile_mailer_mailbox.rb +5 -0
  16. data/test/rails/overrides/app/mailers/decorated_mailer.rb +1 -1
  17. data/test/rails/overrides/db/migrate/20190419005447_create_active_storage_tables.active_storage.rb +27 -0
  18. data/test/rails/overrides/db/migrate/20190419005448_create_action_mailbox_tables.action_mailbox.rb +14 -0
  19. data/test/rails/overrides/spec/controllers/hankaku_filter_controller_spec.rb +1 -1
  20. data/test/rails/overrides/spec/fixtures/{mobile_mailer → files/mobile_mailer}/au-attached.eml +0 -0
  21. data/test/rails/overrides/spec/fixtures/{mobile_mailer → files/mobile_mailer}/au-decomail.eml +0 -0
  22. data/test/rails/overrides/spec/fixtures/{mobile_mailer → files/mobile_mailer}/au-emoji.eml +0 -0
  23. data/test/rails/overrides/spec/fixtures/{mobile_mailer → files/mobile_mailer}/au-emoji2.eml +0 -0
  24. data/test/rails/overrides/spec/fixtures/{mobile_mailer → files/mobile_mailer}/au-emoji5.eml +0 -0
  25. data/test/rails/overrides/spec/fixtures/{mobile_mailer → files/mobile_mailer}/bounced-jp.eml +0 -0
  26. data/test/rails/overrides/spec/fixtures/{mobile_mailer → files/mobile_mailer}/docomo-emoji.eml +0 -0
  27. data/test/rails/overrides/spec/fixtures/{mobile_mailer → files/mobile_mailer}/docomo-gmail-sjis.eml +0 -0
  28. data/test/rails/overrides/spec/fixtures/{mobile_mailer → files/mobile_mailer}/docomo-jis.eml +0 -0
  29. data/{spec/unit/email-fixtures → test/rails/overrides/spec/fixtures/files/mobile_mailer}/iphone-message.eml +0 -0
  30. data/test/rails/overrides/spec/fixtures/{mobile_mailer → files/mobile_mailer}/no-from.eml +0 -0
  31. data/test/rails/overrides/spec/fixtures/{mobile_mailer → files/mobile_mailer}/non-jp.eml +0 -0
  32. data/test/rails/overrides/spec/fixtures/{mobile_mailer → files/mobile_mailer}/photo.jpg +0 -0
  33. data/test/rails/overrides/spec/fixtures/{mobile_mailer → files/mobile_mailer}/softbank-blank.eml +0 -0
  34. data/test/rails/overrides/spec/fixtures/{mobile_mailer → files/mobile_mailer}/softbank-emoji-utf8.eml +0 -0
  35. data/test/rails/overrides/spec/fixtures/{mobile_mailer → files/mobile_mailer}/softbank-emoji.eml +0 -0
  36. data/test/rails/overrides/spec/fixtures/{mobile_mailer → files/mobile_mailer}/softbank-gmail-sjis.eml +0 -0
  37. data/test/rails/overrides/spec/fixtures/{mobile_mailer → files/mobile_mailer}/softbank-gmail-utf8.eml +0 -0
  38. data/test/rails/overrides/spec/mailboxes/mobile_mailer_mailbox_spec.rb +265 -0
  39. data/test/rails/overrides/spec/mailers/mobile_mailer_spec.rb +0 -305
  40. metadata +53 -44
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 585b9e071125feef265a6766b2acd3c5712a62a766a021e779509932be267ba6
4
- data.tar.gz: f8537c94f81cb7204073804469cac44f68dd679712dbe3e5834e3d9332d6125e
3
+ metadata.gz: 4d72106e4eade4a0d0c017d02fbad34f7bcf5cb3dadf94f460f41e877c5d66dc
4
+ data.tar.gz: 2eea7e031ab65c9ce39f95521bc17b4e1929fc3bf4c3bd52588b4825145a51d2
5
5
  SHA512:
6
- metadata.gz: cb2ba84963e1b447fdb422b023ae283424ebff780e454b287ee0c7795c8d63dd9062b1b64b74bbd4c8b67d1c69b7a484622c51b1a7538f4d77966cdcff2a1a58
7
- data.tar.gz: 105df200c744ac957dad1be0bf74ad44ff62699569b0d9027bb9d32b9e1aa46dc71cf7747909a39c7b4b9bebef3e93095f103450d23f6d53f26c374710dfc5c1
6
+ metadata.gz: 7f9f71bc3516f152146927f3034962bd0da171236d1190fd18696b99897a6a6901f2ec1c8d125cd29d2b018be20bd124d03ba289d6cdf84b6879ff937672b238
7
+ data.tar.gz: f5cfa29eee46c9bf236e8e25038fe20e14c9ce768f74c0a6813bcdf794011aa78352d138b3658ae9654c34c34af5c1378df3bb7ec7269967f4d9eb4a87b9838a
@@ -3,7 +3,7 @@ jobs:
3
3
  test-job:
4
4
  working_directory: ~/jpmobile
5
5
  docker:
6
- - image: circleci/ruby:2.5-node-browsers
6
+ - image: circleci/ruby:2.6-node-browsers
7
7
  environment:
8
8
  BUNDLE_JOBS: 3
9
9
  BUNDLE_RETRY: 3
@@ -1 +1 @@
1
- 2.5.1
1
+ 2.6.3
@@ -1,81 +1,96 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- jpmobile (5.2.2)
4
+ jpmobile (6.0.0.beta)
5
5
  mail (~> 2.7.0)
6
6
 
7
7
  GEM
8
8
  remote: https://rubygems.org/
9
9
  specs:
10
- actioncable (5.2.2)
11
- actionpack (= 5.2.2)
10
+ actioncable (6.0.0.rc1)
11
+ actionpack (= 6.0.0.rc1)
12
12
  nio4r (~> 2.0)
13
13
  websocket-driver (>= 0.6.1)
14
- actionmailer (5.2.2)
15
- actionpack (= 5.2.2)
16
- actionview (= 5.2.2)
17
- activejob (= 5.2.2)
14
+ actionmailbox (6.0.0.rc1)
15
+ actionpack (= 6.0.0.rc1)
16
+ activejob (= 6.0.0.rc1)
17
+ activerecord (= 6.0.0.rc1)
18
+ activestorage (= 6.0.0.rc1)
19
+ activesupport (= 6.0.0.rc1)
20
+ mail (>= 2.7.1)
21
+ actionmailer (6.0.0.rc1)
22
+ actionpack (= 6.0.0.rc1)
23
+ actionview (= 6.0.0.rc1)
24
+ activejob (= 6.0.0.rc1)
18
25
  mail (~> 2.5, >= 2.5.4)
19
26
  rails-dom-testing (~> 2.0)
20
- actionpack (5.2.2)
21
- actionview (= 5.2.2)
22
- activesupport (= 5.2.2)
27
+ actionpack (6.0.0.rc1)
28
+ actionview (= 6.0.0.rc1)
29
+ activesupport (= 6.0.0.rc1)
23
30
  rack (~> 2.0)
24
31
  rack-test (>= 0.6.3)
25
32
  rails-dom-testing (~> 2.0)
26
33
  rails-html-sanitizer (~> 1.0, >= 1.0.2)
27
- actionview (5.2.2)
28
- activesupport (= 5.2.2)
34
+ actiontext (6.0.0.rc1)
35
+ actionpack (= 6.0.0.rc1)
36
+ activerecord (= 6.0.0.rc1)
37
+ activestorage (= 6.0.0.rc1)
38
+ activesupport (= 6.0.0.rc1)
39
+ nokogiri (>= 1.8.5)
40
+ actionview (6.0.0.rc1)
41
+ activesupport (= 6.0.0.rc1)
29
42
  builder (~> 3.1)
30
43
  erubi (~> 1.4)
31
44
  rails-dom-testing (~> 2.0)
32
45
  rails-html-sanitizer (~> 1.0, >= 1.0.3)
33
- activejob (5.2.2)
34
- activesupport (= 5.2.2)
46
+ activejob (6.0.0.rc1)
47
+ activesupport (= 6.0.0.rc1)
35
48
  globalid (>= 0.3.6)
36
- activemodel (5.2.2)
37
- activesupport (= 5.2.2)
38
- activerecord (5.2.2)
39
- activemodel (= 5.2.2)
40
- activesupport (= 5.2.2)
41
- arel (>= 9.0)
42
- activestorage (5.2.2)
43
- actionpack (= 5.2.2)
44
- activerecord (= 5.2.2)
49
+ activemodel (6.0.0.rc1)
50
+ activesupport (= 6.0.0.rc1)
51
+ activerecord (6.0.0.rc1)
52
+ activemodel (= 6.0.0.rc1)
53
+ activesupport (= 6.0.0.rc1)
54
+ activestorage (6.0.0.rc1)
55
+ actionpack (= 6.0.0.rc1)
56
+ activejob (= 6.0.0.rc1)
57
+ activerecord (= 6.0.0.rc1)
45
58
  marcel (~> 0.3.1)
46
- activesupport (5.2.2)
59
+ activesupport (6.0.0.rc1)
47
60
  concurrent-ruby (~> 1.0, >= 1.0.2)
48
61
  i18n (>= 0.7, < 2)
49
62
  minitest (~> 5.1)
50
63
  tzinfo (~> 1.1)
51
- addressable (2.5.2)
64
+ zeitwerk (~> 2.1, >= 2.1.4)
65
+ addressable (2.6.0)
52
66
  public_suffix (>= 2.0.2, < 4.0)
53
- arel (9.0.0)
54
67
  ast (2.4.0)
55
68
  builder (3.2.3)
56
- capybara (3.0.1)
69
+ capybara (3.18.0)
57
70
  addressable
58
71
  mini_mime (>= 0.1.3)
59
72
  nokogiri (~> 1.8)
60
73
  rack (>= 1.6.0)
61
74
  rack-test (>= 0.6.3)
62
- xpath (~> 3.0)
63
- capybara-webkit (1.15.0)
75
+ regexp_parser (~> 1.2)
76
+ xpath (~> 3.2)
77
+ capybara-webkit (1.15.1)
64
78
  capybara (>= 2.3, < 4.0)
65
79
  json
66
80
  coderay (1.1.2)
67
- concurrent-ruby (1.1.3)
81
+ concurrent-ruby (1.1.5)
68
82
  crass (1.0.4)
69
83
  diff-lcs (1.3)
70
- erubi (1.7.1)
71
- geokit (1.11.0)
72
- git (1.3.0)
73
- globalid (0.4.1)
84
+ erubi (1.8.0)
85
+ geokit (1.13.1)
86
+ git (1.5.0)
87
+ globalid (0.4.2)
74
88
  activesupport (>= 4.2.0)
75
89
  hpricot (0.8.6)
76
- i18n (1.1.1)
90
+ i18n (1.6.0)
77
91
  concurrent-ruby (~> 1.0)
78
- json (2.1.0)
92
+ jaro_winkler (1.5.2)
93
+ json (2.2.0)
79
94
  loofah (2.2.3)
80
95
  crass (~> 1.0.2)
81
96
  nokogiri (>= 1.5.9)
@@ -84,87 +99,89 @@ GEM
84
99
  marcel (0.3.3)
85
100
  mimemagic (~> 0.3.2)
86
101
  method_source (0.9.2)
87
- mimemagic (0.3.2)
102
+ mimemagic (0.3.3)
88
103
  mini_mime (1.0.1)
89
- mini_portile2 (2.3.0)
104
+ mini_portile2 (2.4.0)
90
105
  minitest (5.11.3)
91
106
  nio4r (2.3.1)
92
- nokogiri (1.8.5)
93
- mini_portile2 (~> 2.3.0)
94
- onkcop (0.53.0.0)
95
- rubocop (~> 0.53.0)
107
+ nokogiri (1.10.3)
108
+ mini_portile2 (~> 2.4.0)
109
+ onkcop (0.53.0.3)
110
+ rubocop (>= 0.53.0)
96
111
  rubocop-rspec (>= 1.24.0)
97
- parallel (1.12.1)
98
- parser (2.5.0.5)
112
+ parallel (1.17.0)
113
+ parser (2.6.3.0)
99
114
  ast (~> 2.4.0)
100
- powerpack (0.1.1)
101
- pry (0.11.3)
115
+ pry (0.12.2)
102
116
  coderay (~> 1.1.0)
103
117
  method_source (~> 0.9.0)
104
- public_suffix (3.0.2)
105
- rack (2.0.6)
118
+ public_suffix (3.0.3)
119
+ rack (2.0.7)
106
120
  rack-test (1.1.0)
107
121
  rack (>= 1.0, < 3)
108
- rails (5.2.2)
109
- actioncable (= 5.2.2)
110
- actionmailer (= 5.2.2)
111
- actionpack (= 5.2.2)
112
- actionview (= 5.2.2)
113
- activejob (= 5.2.2)
114
- activemodel (= 5.2.2)
115
- activerecord (= 5.2.2)
116
- activestorage (= 5.2.2)
117
- activesupport (= 5.2.2)
122
+ rails (6.0.0.rc1)
123
+ actioncable (= 6.0.0.rc1)
124
+ actionmailbox (= 6.0.0.rc1)
125
+ actionmailer (= 6.0.0.rc1)
126
+ actionpack (= 6.0.0.rc1)
127
+ actiontext (= 6.0.0.rc1)
128
+ actionview (= 6.0.0.rc1)
129
+ activejob (= 6.0.0.rc1)
130
+ activemodel (= 6.0.0.rc1)
131
+ activerecord (= 6.0.0.rc1)
132
+ activestorage (= 6.0.0.rc1)
133
+ activesupport (= 6.0.0.rc1)
118
134
  bundler (>= 1.3.0)
119
- railties (= 5.2.2)
135
+ railties (= 6.0.0.rc1)
120
136
  sprockets-rails (>= 2.0.0)
121
137
  rails-dom-testing (2.0.3)
122
138
  activesupport (>= 4.2.0)
123
139
  nokogiri (>= 1.6)
124
140
  rails-html-sanitizer (1.0.4)
125
141
  loofah (~> 2.2, >= 2.2.2)
126
- railties (5.2.2)
127
- actionpack (= 5.2.2)
128
- activesupport (= 5.2.2)
142
+ railties (6.0.0.rc1)
143
+ actionpack (= 6.0.0.rc1)
144
+ activesupport (= 6.0.0.rc1)
129
145
  method_source
130
146
  rake (>= 0.8.7)
131
- thor (>= 0.19.0, < 2.0)
147
+ thor (>= 0.20.3, < 2.0)
132
148
  rainbow (3.0.0)
133
- rake (12.3.1)
134
- rspec (3.7.0)
135
- rspec-core (~> 3.7.0)
136
- rspec-expectations (~> 3.7.0)
137
- rspec-mocks (~> 3.7.0)
138
- rspec-core (3.7.1)
139
- rspec-support (~> 3.7.0)
140
- rspec-expectations (3.7.0)
149
+ rake (12.3.2)
150
+ regexp_parser (1.4.0)
151
+ rspec (3.8.0)
152
+ rspec-core (~> 3.8.0)
153
+ rspec-expectations (~> 3.8.0)
154
+ rspec-mocks (~> 3.8.0)
155
+ rspec-core (3.8.0)
156
+ rspec-support (~> 3.8.0)
157
+ rspec-expectations (3.8.3)
141
158
  diff-lcs (>= 1.2.0, < 2.0)
142
- rspec-support (~> 3.7.0)
143
- rspec-its (1.2.0)
159
+ rspec-support (~> 3.8.0)
160
+ rspec-its (1.3.0)
144
161
  rspec-core (>= 3.0.0)
145
162
  rspec-expectations (>= 3.0.0)
146
- rspec-mocks (3.7.0)
163
+ rspec-mocks (3.8.0)
147
164
  diff-lcs (>= 1.2.0, < 2.0)
148
- rspec-support (~> 3.7.0)
149
- rspec-rails (3.7.2)
165
+ rspec-support (~> 3.8.0)
166
+ rspec-rails (3.8.2)
150
167
  actionpack (>= 3.0)
151
168
  activesupport (>= 3.0)
152
169
  railties (>= 3.0)
153
- rspec-core (~> 3.7.0)
154
- rspec-expectations (~> 3.7.0)
155
- rspec-mocks (~> 3.7.0)
156
- rspec-support (~> 3.7.0)
157
- rspec-support (3.7.1)
158
- rubocop (0.53.0)
170
+ rspec-core (~> 3.8.0)
171
+ rspec-expectations (~> 3.8.0)
172
+ rspec-mocks (~> 3.8.0)
173
+ rspec-support (~> 3.8.0)
174
+ rspec-support (3.8.0)
175
+ rubocop (0.68.1)
176
+ jaro_winkler (~> 1.5.1)
159
177
  parallel (~> 1.10)
160
- parser (>= 2.5)
161
- powerpack (~> 0.1)
178
+ parser (>= 2.5, != 2.5.1.1)
162
179
  rainbow (>= 2.2.2, < 4.0)
163
180
  ruby-progressbar (~> 1.7)
164
- unicode-display_width (~> 1.0, >= 1.0.1)
165
- rubocop-rspec (1.25.0)
166
- rubocop (>= 0.53.0)
167
- ruby-progressbar (1.9.0)
181
+ unicode-display_width (>= 1.4.0, < 1.6)
182
+ rubocop-rspec (1.32.0)
183
+ rubocop (>= 0.60.0)
184
+ ruby-progressbar (1.10.0)
168
185
  sprockets (3.7.2)
169
186
  concurrent-ruby (~> 1.0)
170
187
  rack (> 1, < 3)
@@ -172,19 +189,20 @@ GEM
172
189
  actionpack (>= 4.0)
173
190
  activesupport (>= 4.0)
174
191
  sprockets (>= 3.0.0)
175
- sqlite3 (1.3.13)
192
+ sqlite3 (1.4.1)
176
193
  sqlite3-ruby (1.3.3)
177
194
  sqlite3 (>= 1.3.3)
178
195
  thor (0.20.3)
179
196
  thread_safe (0.3.6)
180
197
  tzinfo (1.2.5)
181
198
  thread_safe (~> 0.1)
182
- unicode-display_width (1.3.0)
199
+ unicode-display_width (1.5.0)
183
200
  websocket-driver (0.7.0)
184
201
  websocket-extensions (>= 0.1.0)
185
202
  websocket-extensions (0.1.3)
186
- xpath (3.0.0)
203
+ xpath (3.2.0)
187
204
  nokogiri (~> 1.8)
205
+ zeitwerk (2.1.6)
188
206
 
189
207
  PLATFORMS
190
208
  ruby
@@ -197,7 +215,7 @@ DEPENDENCIES
197
215
  jpmobile!
198
216
  onkcop
199
217
  pry
200
- rails (~> 5.2.0)
218
+ rails (~> 6.0.0.rc1)
201
219
  rspec
202
220
  rspec-its
203
221
  rspec-rails
@@ -205,4 +223,4 @@ DEPENDENCIES
205
223
  sqlite3-ruby
206
224
 
207
225
  BUNDLED WITH
208
- 1.16.4
226
+ 1.17.2
@@ -22,7 +22,7 @@ Gem::Specification.new do |gem|
22
22
  gem.add_development_dependency 'git'
23
23
  gem.add_development_dependency 'hpricot'
24
24
  gem.add_development_dependency 'pry'
25
- gem.add_development_dependency 'rails', '~> 5.2.0'
25
+ gem.add_development_dependency 'rails', '~> 6.0.0.rc1'
26
26
  gem.add_development_dependency 'rspec'
27
27
  gem.add_development_dependency 'rspec-its'
28
28
  gem.add_development_dependency 'rspec-rails'
@@ -11,18 +11,12 @@ end
11
11
  # :stopdoc:
12
12
  # accept-charset に charset を変更できるようにする
13
13
  module Jpmobile
14
- module ActionView
15
- module HtmlOptionsWithAcceptCharset
16
- private
17
-
18
- def html_options_for_form(url_for_options, options, *parameters_for_url)
19
- super.tap do |o|
20
- o['accept-charset'] = (Rails.application.config.jpmobile.form_accept_charset_conversion && request && request.mobile && request.mobile.default_charset) || o['accept-charset']
21
- end
14
+ module HtmlOptionsWithAcceptCharset
15
+ def html_options_for_form(url_for_options, options)
16
+ super.tap do |o|
17
+ o['accept-charset'] = (Rails.application.config.jpmobile.form_accept_charset_conversion && request && request.mobile && request.mobile.default_charset) || o['accept-charset']
22
18
  end
23
19
  end
24
20
  end
25
21
  end
26
-
27
- ::ActionView::Helpers::FormTagHelper.send :prepend, Jpmobile::ActionView::HtmlOptionsWithAcceptCharset
28
22
  #:startdoc:
@@ -12,6 +12,8 @@ end
12
12
 
13
13
  ActiveSupport.on_load(:action_view) do
14
14
  require 'jpmobile/hook_action_view'
15
+
16
+ self.prepend Jpmobile::HtmlOptionsWithAcceptCharset
15
17
  end
16
18
 
17
19
  ActiveSupport.on_load(:after_initialize) do
@@ -5,43 +5,9 @@ module Jpmobile
5
5
 
6
6
  def initialize(path, pattern = nil)
7
7
  raise ArgumentError, 'path already is a Resolver class' if path.is_a?(Resolver)
8
-
9
- super(path, pattern || DEFAULT_PATTERN)
8
+ super
9
+ @pattern = DEFAULT_PATTERN
10
10
  @path = File.expand_path(path)
11
11
  end
12
-
13
- private
14
-
15
- def query(path, details, formats, outside_app_allowed)
16
- query = build_query(path, details)
17
-
18
- template_paths = find_template_paths(query)
19
- template_paths = reject_files_external_to_app(template_paths) unless outside_app_allowed
20
-
21
- template_paths.map do |template|
22
- handler, format, variant = extract_handler_and_format_and_variant(template)
23
- contents = File.binread(template)
24
-
25
- virtual_path = if format
26
- if template =~ /.+#{path}(.+)\.#{format.to_sym.to_s}.*$/
27
- path.to_str + Regexp.last_match(1)
28
- else
29
- path.virtual
30
- end
31
- else
32
- path.virtual
33
- end
34
-
35
- ::ActionView::Template.new(
36
- contents,
37
- File.expand_path(template),
38
- handler,
39
- virtual_path: virtual_path,
40
- format: format,
41
- variant: variant,
42
- updated_at: mtime(template),
43
- )
44
- end
45
- end
46
12
  end
47
13
  end
@@ -1,3 +1,3 @@
1
1
  module Jpmobile
2
- VERSION = '5.2.5'.freeze
2
+ VERSION = '6.0.0.beta'.freeze
3
3
  end
@@ -94,8 +94,8 @@ namespace :test do
94
94
 
95
95
  unless skip
96
96
  # add gems for jpmobile spec
97
- config_path = File.join(rails_root, 'Gemfile')
98
- File.open(config_path, 'a+') do |file|
97
+ gemfile_path = File.join(rails_root, 'Gemfile')
98
+ File.open(gemfile_path, 'a+') do |file|
99
99
  file.write <<-GEMFILE
100
100
  instance_eval File.read(File.expand_path(__FILE__) + '.jpmobile')
101
101
  GEMFILE
@@ -84,7 +84,7 @@ describe 'Jpmobile::Mail#receive' do
84
84
  describe 'Docomo' do
85
85
  context 'with sjis decomail' do
86
86
  before(:each) do
87
- @mail = Mail.new(File.open(File.join(__dir__, '../../test/rails/overrides/spec/fixtures/mobile_mailer/docomo-gmail-sjis.eml')).read)
87
+ @mail = Mail.new(File.open(File.join(__dir__, '../../test/rails/overrides/spec/fixtures/files/mobile_mailer/docomo-gmail-sjis.eml')).read)
88
88
  end
89
89
 
90
90
  it 'subject should be parsed correctly' do
@@ -129,7 +129,7 @@ describe 'Jpmobile::Mail#receive' do
129
129
 
130
130
  describe 'Au' do
131
131
  before(:each) do
132
- @mail = Mail.new(File.open(File.join(__dir__, '../../test/rails/overrides/spec/fixtures/mobile_mailer/au-decomail.eml')).read)
132
+ @mail = Mail.new(File.open(File.join(__dir__, '../../test/rails/overrides/spec/fixtures/files/mobile_mailer/au-decomail.eml')).read)
133
133
  end
134
134
 
135
135
  it 'subject should be parsed correctly' do
@@ -151,7 +151,7 @@ describe 'Jpmobile::Mail#receive' do
151
151
  describe 'Softbank' do
152
152
  context 'Shift_JIS' do
153
153
  before(:each) do
154
- @mail = Mail.new(File.open(File.join(__dir__, '../../test/rails/overrides/spec/fixtures/mobile_mailer/softbank-gmail-sjis.eml')).read)
154
+ @mail = Mail.new(File.open(File.join(__dir__, '../../test/rails/overrides/spec/fixtures/files/mobile_mailer/softbank-gmail-sjis.eml')).read)
155
155
  end
156
156
 
157
157
  it 'subject should be parsed correctly' do
@@ -170,7 +170,7 @@ describe 'Jpmobile::Mail#receive' do
170
170
 
171
171
  context 'UTF-8' do
172
172
  before(:each) do
173
- @mail = Mail.new(File.open(File.join(__dir__, '../../test/rails/overrides/spec/fixtures/mobile_mailer/softbank-gmail-utf8.eml')).read)
173
+ @mail = Mail.new(File.open(File.join(__dir__, '../../test/rails/overrides/spec/fixtures/files/mobile_mailer/softbank-gmail-utf8.eml')).read)
174
174
  end
175
175
 
176
176
  it 'subject should be parsed correctly' do
@@ -304,13 +304,13 @@ describe 'Jpmobile::Mail#receive' do
304
304
 
305
305
  context 'From au iPhone' do
306
306
  it 'charset should be UTF-8' do
307
- @mail = Mail.new(File.open(File.join(__dir__, 'email-fixtures/iphone-message.eml')).read)
307
+ @mail = Mail.new(File.open(File.join(__dir__, '../../test/rails/overrides/spec/fixtures/files/mobile_mailer/iphone-message.eml')).read)
308
308
  expect(@mail.mobile).to be_a(Jpmobile::Mobile::Au)
309
309
  expect(@mail.charset).to match(/utf-8/i)
310
310
  end
311
311
 
312
312
  it 'should be encoded correctly' do
313
- @mail = Mail.new(File.open(File.join(__dir__, 'email-fixtures/iphone-message.eml')).read)
313
+ @mail = Mail.new(File.open(File.join(__dir__, '../../test/rails/overrides/spec/fixtures/files/mobile_mailer/iphone-message.eml')).read)
314
314
  expect(@mail.encoded).to match(Regexp.escape("%[\e$B1`;yL>\e(B]%\e$B$N\e(B%[\e$BJ]8n<TL>\e(B]%"))
315
315
  end
316
316
 
@@ -435,7 +435,7 @@ describe 'Jpmobile::Mail#receive' do
435
435
  describe 'bounced mail' do
436
436
  context 'has jp address' do
437
437
  before(:each) do
438
- @mail = Mail.new(File.open(File.join(__dir__, '../../test/rails/overrides/spec/fixtures/mobile_mailer/bounced-jp.eml')).read)
438
+ @mail = Mail.new(File.open(File.join(__dir__, '../../test/rails/overrides/spec/fixtures/files/mobile_mailer/bounced-jp.eml')).read)
439
439
  end
440
440
 
441
441
  it 'mobile should abstract mobile' do
@@ -447,7 +447,7 @@ describe 'Jpmobile::Mail#receive' do
447
447
  describe 'non-Japanese mail' do
448
448
  context 'us-ascii' do
449
449
  before(:each) do
450
- @mail = Mail.new(File.open(File.join(__dir__, '../../test/rails/overrides/spec/fixtures/mobile_mailer/non-jp.eml')).read)
450
+ @mail = Mail.new(File.open(File.join(__dir__, '../../test/rails/overrides/spec/fixtures/files/mobile_mailer/non-jp.eml')).read)
451
451
  end
452
452
 
453
453
  it 'mobile should be nil' do
@@ -458,7 +458,7 @@ describe 'Jpmobile::Mail#receive' do
458
458
 
459
459
  context 'no From header' do
460
460
  before(:each) do
461
- @mail = Mail.new(File.open(File.join(__dir__, '../../test/rails/overrides/spec/fixtures/mobile_mailer/no-from.eml')).read)
461
+ @mail = Mail.new(File.open(File.join(__dir__, '../../test/rails/overrides/spec/fixtures/files/mobile_mailer/no-from.eml')).read)
462
462
  end
463
463
 
464
464
  it 'mobile should be nil' do