Commit 0fc4a35b8b0a66f85caf242c34c29b5bb069c0ca
1 parent
1a8aab81
Exists in
master
and in
29 other branches
Reducing size of favorite enterprise confirm button
Also replaced create_user by fast_create on test (ActionItem356)
Showing
2 changed files
with
3 additions
and
4 deletions
Show diff stats
app/views/favorite_enterprises/add.rhtml
| ... | ... | @@ -7,6 +7,6 @@ |
| 7 | 7 | <% form_tag do %> |
| 8 | 8 | <%= hidden_field_tag(:confirmation, 1) %> |
| 9 | 9 | |
| 10 | - <%= submit_button(:ok, __("Yes, I want to add %s as a favorite enterprise") % @favorite_enterprise.name) %> | |
| 10 | + <%= submit_button(:ok, __("Yes, I am sure"), :title => _("I want to add %s as a favorite enterprise") % @favorite_enterprise.name) %> | |
| 11 | 11 | <%= button(:cancel, _("No, I don't want"), :action => 'index') %> |
| 12 | 12 | <% end %> | ... | ... |
test/unit/enterprise_test.rb
| ... | ... | @@ -50,13 +50,12 @@ class EnterpriseTest < Test::Unit::TestCase |
| 50 | 50 | end |
| 51 | 51 | |
| 52 | 52 | should 'have fans' do |
| 53 | - p = create_user('test_person').person | |
| 53 | + p = fast_create(Person) | |
| 54 | 54 | e = fast_create(Enterprise) |
| 55 | 55 | |
| 56 | 56 | p.favorite_enterprises << e |
| 57 | - e.reload | |
| 58 | 57 | |
| 59 | - assert_includes e.fans, p | |
| 58 | + assert_includes Enterprise.find(e.id).fans, p | |
| 60 | 59 | end |
| 61 | 60 | |
| 62 | 61 | should 'remove products when removing enterprise' do | ... | ... |