Skip to content

Commit

Permalink
Merge pull request #167 from internetee/update-rails-to-5-2-1-1
Browse files Browse the repository at this point in the history
Update rails to 5.2.1.1
  • Loading branch information
vohmar authored Nov 30, 2018
2 parents 28bd500 + c2f1cbe commit e7d7f69
Show file tree
Hide file tree
Showing 8 changed files with 94 additions and 51 deletions.
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ before_script:
- "chmod +x ./cc-test-reporter"
- "./cc-test-reporter before-build"
script:
- "bundle exec rails test"
- "bundle exec rails test test/*"
after_script:
- "./cc-test-reporter after-build --exit-code $TRAVIS_TEST_RESULT"
services:
Expand Down
84 changes: 42 additions & 42 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2,43 +2,43 @@ GEM
remote: https://rubygems.org/
specs:
SyslogLogger (2.0)
actioncable (5.2.1)
actionpack (= 5.2.1)
actioncable (5.2.1.1)
actionpack (= 5.2.1.1)
nio4r (~> 2.0)
websocket-driver (>= 0.6.1)
actionmailer (5.2.1)
actionpack (= 5.2.1)
actionview (= 5.2.1)
activejob (= 5.2.1)
actionmailer (5.2.1.1)
actionpack (= 5.2.1.1)
actionview (= 5.2.1.1)
activejob (= 5.2.1.1)
mail (~> 2.5, >= 2.5.4)
rails-dom-testing (~> 2.0)
actionpack (5.2.1)
actionview (= 5.2.1)
activesupport (= 5.2.1)
actionpack (5.2.1.1)
actionview (= 5.2.1.1)
activesupport (= 5.2.1.1)
rack (~> 2.0)
rack-test (>= 0.6.3)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.0, >= 1.0.2)
actionview (5.2.1)
activesupport (= 5.2.1)
actionview (5.2.1.1)
activesupport (= 5.2.1.1)
builder (~> 3.1)
erubi (~> 1.4)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.0, >= 1.0.3)
activejob (5.2.1)
activesupport (= 5.2.1)
activejob (5.2.1.1)
activesupport (= 5.2.1.1)
globalid (>= 0.3.6)
activemodel (5.2.1)
activesupport (= 5.2.1)
activerecord (5.2.1)
activemodel (= 5.2.1)
activesupport (= 5.2.1)
activemodel (5.2.1.1)
activesupport (= 5.2.1.1)
activerecord (5.2.1.1)
activemodel (= 5.2.1.1)
activesupport (= 5.2.1.1)
arel (>= 9.0)
activestorage (5.2.1)
actionpack (= 5.2.1)
activerecord (= 5.2.1)
activestorage (5.2.1.1)
actionpack (= 5.2.1.1)
activerecord (= 5.2.1.1)
marcel (~> 0.3.1)
activesupport (5.2.1)
activesupport (5.2.1.1)
concurrent-ruby (~> 1.0, >= 1.0.2)
i18n (>= 0.7, < 2)
minitest (~> 5.1)
Expand All @@ -57,7 +57,7 @@ GEM
rack-test (>= 0.6.3)
xpath (~> 3.1)
coderay (1.1.2)
concurrent-ruby (1.0.5)
concurrent-ruby (1.1.3)
crack (0.4.3)
safe_yaml (~> 1.0.0)
crass (1.0.4)
Expand All @@ -70,7 +70,7 @@ GEM
globalid (0.4.1)
activesupport (>= 4.2.0)
hashdiff (0.3.7)
i18n (1.1.0)
i18n (1.1.1)
concurrent-ruby (~> 1.0)
jbuilder (2.7.0)
activesupport (>= 4.2.0)
Expand All @@ -84,11 +84,11 @@ GEM
loofah (2.2.3)
crass (~> 1.0.2)
nokogiri (>= 1.5.9)
mail (2.7.0)
mail (2.7.1)
mini_mime (>= 0.1.1)
marcel (0.3.2)
marcel (0.3.3)
mimemagic (~> 0.3.2)
method_source (0.9.0)
method_source (0.9.2)
mimemagic (0.3.2)
mina (0.3.8)
open4 (~> 1.3.4)
Expand All @@ -111,27 +111,27 @@ GEM
rack (2.0.6)
rack-test (1.1.0)
rack (>= 1.0, < 3)
rails (5.2.1)
actioncable (= 5.2.1)
actionmailer (= 5.2.1)
actionpack (= 5.2.1)
actionview (= 5.2.1)
activejob (= 5.2.1)
activemodel (= 5.2.1)
activerecord (= 5.2.1)
activestorage (= 5.2.1)
activesupport (= 5.2.1)
rails (5.2.1.1)
actioncable (= 5.2.1.1)
actionmailer (= 5.2.1.1)
actionpack (= 5.2.1.1)
actionview (= 5.2.1.1)
activejob (= 5.2.1.1)
activemodel (= 5.2.1.1)
activerecord (= 5.2.1.1)
activestorage (= 5.2.1.1)
activesupport (= 5.2.1.1)
bundler (>= 1.3.0)
railties (= 5.2.1)
railties (= 5.2.1.1)
sprockets-rails (>= 2.0.0)
rails-dom-testing (2.0.3)
activesupport (>= 4.2.0)
nokogiri (>= 1.6)
rails-html-sanitizer (1.0.4)
loofah (~> 2.2, >= 2.2.2)
railties (5.2.1)
actionpack (= 5.2.1)
activesupport (= 5.2.1)
railties (5.2.1.1)
actionpack (= 5.2.1.1)
activesupport (= 5.2.1.1)
method_source
rake (>= 0.8.7)
thor (>= 0.19.0, < 2.0)
Expand All @@ -157,7 +157,7 @@ GEM
actionpack (>= 4.0)
activesupport (>= 4.0)
sprockets (>= 3.0.0)
thor (0.20.0)
thor (0.20.3)
thread_safe (0.3.6)
tzinfo (1.2.5)
thread_safe (~> 0.1)
Expand Down
34 changes: 34 additions & 0 deletions config/storage.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
test:
service: Disk
root: <%= Rails.root.join("tmp/storage") %>

local:
service: Disk
root: <%= Rails.root.join("storage") %>

# Use rails credentials:edit to set the AWS secrets (as aws:access_key_id|secret_access_key)
# amazon:
# service: S3
# access_key_id: <%= Rails.application.credentials.dig(:aws, :access_key_id) %>
# secret_access_key: <%= Rails.application.credentials.dig(:aws, :secret_access_key) %>
# region: us-east-1
# bucket: your_own_bucket

# Remember not to checkin your GCS keyfile to a repository
# google:
# service: GCS
# project: your_project
# credentials: <%= Rails.root.join("path/to/gcs.keyfile") %>
# bucket: your_own_bucket

# Use rails credentials:edit to set the Azure Storage secret (as azure_storage:storage_access_key)
# microsoft:
# service: AzureStorage
# storage_account_name: your_account_name
# storage_access_key: <%= Rails.application.credentials.dig(:azure_storage, :storage_access_key) %>
# container: your_container_name

# mirror:
# service: Mirror
# primary: local
# mirrors: [ amazon, google, microsoft ]
4 changes: 3 additions & 1 deletion test/fixtures/contact_request_mailer/confirmation_email.erb
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,6 @@ http://example.test/contact_requests/c57db228289d5cf6c4e109a0cbf9679856dd628a833
Link expires in 24 hours.

Best regards,
Estonian Internet Foundation
Estonian Internet Foundation


Original file line number Diff line number Diff line change
Expand Up @@ -76,4 +76,5 @@ Best regards,
John Smith

С уважением,
Eesti Interneti SA
Eesti Interneti SA

Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,6 @@ http://example.test/contact_requests/c57db228289d5cf6c4e109a0cbf9679856dd628a833
Link aegub 24 tunniga.

Lugupidamisega
Eesti Interneti SA
Eesti Interneti SA


Original file line number Diff line number Diff line change
Expand Up @@ -61,4 +61,5 @@ EIS не проверяет подлинность сообщения и не у
Hello there

С уважением,
Eesti Interneti SA
Eesti Interneti SA

11 changes: 7 additions & 4 deletions test/mailers/contact_request_mailer_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ def test_confirmation_email
assert_equal(['no-reply@internet.ee'], email.from)
assert_equal(['email@example.com'], email.to)
assert_equal('Email address confirmation', email.subject)
assert_equal(read_fixture('confirmation_email.erb').join, email.body.to_s.rstrip)
assert_equal(read_fixture('confirmation_email.erb').join, email.body.to_s.gsub(/\r/, ""))
end

def test_confirmation_email_can_be_localized
Expand All @@ -28,7 +28,8 @@ def test_confirmation_email_can_be_localized
assert_equal(['no-reply@internet.ee'], email.from)
assert_equal(['email@example.com'], email.to)
assert_equal('E-posti aadressi kinnituskiri', email.subject)
assert_equal(read_fixture('localized_confirmation_email.erb').join, email.body.to_s.rstrip)
assert_equal(read_fixture('localized_confirmation_email.erb').join,
email.body.to_s.gsub(/\r/, ""))

I18n.locale = I18n.default_locale
end
Expand All @@ -53,7 +54,8 @@ def test_contact_request_email
assert_equal(['admin@privatedomain.com', 'owner@private_domain.com'], email.to)
assert_equal(['email@example.com'], email.reply_to)
assert_equal('Email to domain owner and/or contact', email.subject)
assert_equal(read_fixture('contact_request_email.erb').join, email.body.to_s.rstrip)
assert_equal(read_fixture('contact_request_email.erb').join,
email.body.to_s.gsub(/\r/, ""))
end

def test_contact_request_email_strips_html_tags_from_body
Expand All @@ -71,7 +73,8 @@ def test_contact_request_email_strips_html_tags_from_body
assert_equal(['admin@privatedomain.com', 'owner@private_domain.com'], email.to)
assert_equal(['email@example.com'], email.reply_to)
assert_equal('Email to domain owner and/or contact', email.subject)
assert_equal(read_fixture('stripped_contact_request_email.erb').join, email.body.to_s.rstrip)
assert_equal(read_fixture('stripped_contact_request_email.erb').join,
email.body.to_s.gsub(/\r/, ""))
end

def test_character_limit_constants_defaults_to_2000
Expand Down

0 comments on commit e7d7f69

Please sign in to comment.