From 351dddff839b915d9c133527a74a74ddb8c1864a Mon Sep 17 00:00:00 2001 From: Jackson Pires Date: Thu, 15 Feb 2018 20:35:53 -0300 Subject: [PATCH] =?UTF-8?q?i18n=20-=20Considera=C3=A7=C3=B5es?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- tdd_app/spec/features/customers_spec.rb | 8 ++++---- tdd_app/spec/rails_helper.rb | 3 +++ 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/tdd_app/spec/features/customers_spec.rb b/tdd_app/spec/features/customers_spec.rb index cf7b0e9..5f07c8b 100644 --- a/tdd_app/spec/features/customers_spec.rb +++ b/tdd_app/spec/features/customers_spec.rb @@ -23,10 +23,10 @@ visit(new_customer_path) customer_name = Faker::Name.name - fill_in('customer_name', with: customer_name) - fill_in('customer_email', with: Faker::Internet.email) - fill_in('customer_phone', with: Faker::PhoneNumber.phone_number) - attach_file('customer_avatar', "#{Rails.root}/spec/fixtures/avatar.png") + fill_in('Nome', with: customer_name) + fill_in('Email', with: Faker::Internet.email) + fill_in('Telefone', with: Faker::PhoneNumber.phone_number) + attach_file('Foto do Perfil', "#{Rails.root}/spec/fixtures/avatar.png") choose(option: ['S','N'].sample) click_on('Criar Cliente') diff --git a/tdd_app/spec/rails_helper.rb b/tdd_app/spec/rails_helper.rb index bbe1ba5..742d993 100644 --- a/tdd_app/spec/rails_helper.rb +++ b/tdd_app/spec/rails_helper.rb @@ -26,6 +26,9 @@ # If you are not using ActiveRecord, you can remove this line. ActiveRecord::Migration.maintain_test_schema! +# i18n +I18n.locale = :'pt-BR' + RSpec.configure do |config| # Remove this line if you're not using ActiveRecord or ActiveRecord fixtures config.fixture_path = "#{::Rails.root}/spec/fixtures"