Fix button labels on terms of service

This commit is contained in:
Lucas da Costa
2022-07-19 22:53:30 -03:00
parent 3d6842db80
commit 35030bfd02
3 changed files with 6 additions and 3 deletions

View File

@@ -14,6 +14,6 @@
= t(".using_default_terms_html", tos_link: link_to_platform_terms)
= form_for [main_app, :admin, @new_file] do |f|
= f.label :attachment
= f.label :attachment, t(".attachment")
= f.file_field :attachment
= f.submit
= f.submit t(".create_terms_of_service")

View File

@@ -542,6 +542,8 @@ en:
terms_of_service: "Terms of Service"
delete: "Delete file"
confirm_delete: "Are you sure you want to delete the current Terms of Service file?"
attachment: "Attachment"
create_terms_of_service: "Create Terms of service file"
number_localization:
number_localization_settings: "Number Localization Settings"
enable_localized_number: "Use the international thousand/decimal separator logic"

View File

@@ -34,7 +34,8 @@ describe "Terms of Service files" do
it "can delete the current file", js: true do
attachment = File.open(Rails.root.join(test_file_path))
TermsOfServiceFile.create!(attachment: attachment)
file = Rack::Test::UploadedFile.new(attachment, "application/pdf")
TermsOfServiceFile.create!(attachment: file)
visit admin_terms_of_service_files_path