mirror of
https://github.com/discourse/discourse.git
synced 2025-05-30 07:11:34 +08:00
DEV: Correctly pluralize error messages (#26469)
This commit is contained in:
@ -777,7 +777,7 @@ RSpec.describe ThemeSettingsObjectValidator do
|
||||
expect(errors.keys).to eq(["/tags_property"])
|
||||
|
||||
expect(errors["/tags_property"].full_messages).to contain_exactly(
|
||||
"must have at least 1 tag names",
|
||||
"must have at least 1 tag name",
|
||||
)
|
||||
|
||||
errors =
|
||||
@ -912,7 +912,7 @@ RSpec.describe ThemeSettingsObjectValidator do
|
||||
expect(errors.keys).to eq(["/group_property"])
|
||||
|
||||
expect(errors["/group_property"].full_messages).to contain_exactly(
|
||||
"must have at least 1 group ids",
|
||||
"must have at least 1 group id",
|
||||
)
|
||||
|
||||
errors =
|
||||
@ -1154,7 +1154,7 @@ RSpec.describe ThemeSettingsObjectValidator do
|
||||
expect(errors.keys).to eq(["/category_property"])
|
||||
|
||||
expect(errors["/category_property"].full_messages).to contain_exactly(
|
||||
"must have at least 1 category ids",
|
||||
"must have at least 1 category id",
|
||||
)
|
||||
end
|
||||
|
||||
|
@ -29,7 +29,7 @@ RSpec.describe ThemeSettingsValidator do
|
||||
)
|
||||
|
||||
expect(errors).to contain_exactly(
|
||||
"The property at JSON Pointer '/0/name' must be at most 1 characters long.",
|
||||
"The property at JSON Pointer '/0/name' must be at most 1 character long.",
|
||||
)
|
||||
end
|
||||
end
|
||||
|
Reference in New Issue
Block a user