Commit 5d15fae2c64c756400d0bfca8d932394e9d15511
1 parent
2d846835
Exists in
master
and in
1 other branch
update appearances test to have cleaner output
Showing
1 changed file
with
3 additions
and
3 deletions
Show diff stats
lib/tasks/test_api.rake
... | ... | @@ -50,8 +50,8 @@ namespace :test_api do |
50 | 50 | |
51 | 51 | def verify_choice_appearances_and_votes(choice) |
52 | 52 | success_message = "Choice has more appearances than votes and skips" |
53 | - prompts_on_left = choice.prompts_on_the_left { |p| p.id } | |
54 | - prompts_on_right = choice.prompts_on_the_right { |p| p.id } | |
53 | + prompts_on_left = choice.prompts_on_the_left.map { |p| p.id } | |
54 | + prompts_on_right = choice.prompts_on_the_right.map { |p| p.id } | |
55 | 55 | all_prompt_ids = prompts_on_left + prompts_on_right |
56 | 56 | all_appearances = Appearance.count(:conditions => { :prompt_id => all_prompt_ids}) |
57 | 57 | skips = Skip.count(:conditions => {:prompt_id => all_prompt_ids}) |
... | ... | @@ -462,7 +462,7 @@ namespace :test_api do |
462 | 462 | unless question_has_votes_before_2010_02_17 |
463 | 463 | message, error_occurred = verify_choice_appearances_and_votes(choice) |
464 | 464 | if error_occurred |
465 | - error_message += message | |
465 | + error_message += message + "\n" | |
466 | 466 | end |
467 | 467 | end |
468 | 468 | ... | ... |