A platform for community discussion. Free, open, simple.
DEV: fix deprecation warnings in specs
Régis Hanol821e9207111a
diff --git a/config/locales/server.en.yml b/config/locales/server.en.ymlindex 661bd4b008d..90653d84bbf 100644--- a/config/locales/server.en.yml+++ b/config/locales/server.en.yml@@ -335,7 +335,7 @@ en:user_is_suspended: "Suspended users are not allowed to post."topic_not_found: "Something has gone wrong. Perhaps this topic was closed or deleted while you were looking at it?"not_accepting_pms: "Sorry, %{username} is not accepting messages at the moment."- max_pm_recepients: "Sorry, you can send a message to maximum %{recipients_limit} recipients."+ max_pm_recipients: "Sorry, you can send a message to maximum %{recipients_limit} recipients."pm_reached_recipients_limit: "Sorry, you can't have more than %{recipients_limit} recipients in a message."removed_direct_reply_full_quotes: "Automatically removed quote of whole previous post."secure_upload_not_allowed_in_public_topic: "Sorry, the following secure upload(s) cannot be used in a public topic: %{upload_filenames}."diff --git a/lib/post_creator.rb b/lib/post_creator.rbindex 820bc1e87a5..d96250d9ec6 100644--- a/lib/post_creator.rb+++ b/lib/post_creator.rb@@ -104,7 +104,7 @@ class PostCreatorif names.length > max_allowed_message_recipientserrors.add(:base,- I18n.t(:max_pm_recepients, recipients_limit: max_allowed_message_recipients)+ I18n.t(:max_pm_recipients, recipients_limit: max_allowed_message_recipients))return falsediff --git a/spec/models/topic_user_spec.rb b/spec/models/topic_user_spec.rbindex 5f2f16d6aaa..48fa3d54987 100644--- a/spec/models/topic_user_spec.rb+++ b/spec/models/topic_user_spec.rb@@ -246,7 +246,7 @@ describe TopicUser dolet(:topic) { post.topic }- it 'should ensure recepients and senders are watching' do+ it 'should ensure recipients and senders are watching' doexpect(TopicUser.get(topic, post.user).notification_level).to eq(TopicUser.notification_levels[:watching])diff --git a/spec/requests/posts_controller_spec.rb b/spec/requests/posts_controller_spec.rbindex d2818f50de2..57d9cf5d00e 100644--- a/spec/requests/posts_controller_spec.rb+++ b/spec/requests/posts_controller_spec.rb@@ -939,7 +939,7 @@ describe PostsController dopost "/posts.json", params: {raw: 'I can haz a test',title: 'I loves my test',- target_usernames: group.name,+ target_recipients: group.name,archetype: Archetype.private_message}@@ -951,7 +951,7 @@ describe PostsController dopost "/posts.json", params: {raw: 'I can haz a test',title: 'I loves my test',- target_usernames: group.name,+ target_recipients: group.name,archetype: Archetype.private_message}@@ -1097,7 +1097,7 @@ describe PostsController doraw: 'this is the test content',archetype: 'private_message',title: "this is some post",- target_usernames: "#{user_2.username},#{user_3.username}"+ target_recipients: "#{user_2.username},#{user_3.username}"}expect(response.status).to eq(200)@@ -1240,7 +1240,7 @@ describe PostsController doraw: 'this is the test content',archetype: 'private_message',title: "this is some post",- target_usernames: user_2.username,+ target_recipients: user_2.username,is_warning: true}@@ -1257,7 +1257,7 @@ describe PostsController doraw: 'this is the test content',archetype: 'private_message',title: "this is some post",- target_usernames: user_2.username,+ target_recipients: user_2.username,is_warning: false}@@ -1277,7 +1277,7 @@ describe PostsController doraw: 'this is the test content',archetype: 'private_message',title: "this is some post",- target_usernames: user_2.username,+ target_recipients: user_2.username,is_warning: true}