Commit 9579015b88a2beb1e904757bcf69936a8f861229

Authored by Luke Baker
2 parents 2e9e5c92 46ea7e43

Merge branch 'master' into atomic-appearance-updates

app/models/choice.rb
... ... @@ -40,7 +40,7 @@ class Choice < ActiveRecord::Base
40 40 if self.changed.include?('active') && self.active?
41 41 self.question.mark_prompt_queue_for_refill
42 42 if self.question.choices.size - self.question.inactive_choices_count > 1 && self.question.uses_catchup?
43   - self.question.send_later :add_prompt_to_queue
  43 + self.question.delay.add_prompt_to_queue
44 44 end
45 45 end
46 46 end
... ...
app/models/question.rb
... ... @@ -83,7 +83,7 @@ class Question < ActiveRecord::Base
83 83 else
84 84 record_prompt_cache_hit
85 85 end
86   - self.send_later :add_prompt_to_queue
  86 + self.delay.add_prompt_to_queue
87 87 return next_prompt
88 88 else
89 89 #Standard choose prompt at random
... ...
spec/integration/questions_spec.rb
... ... @@ -83,7 +83,7 @@ describe "Questions" do
83 83 response.body.should have_tag("question", @questions.size)
84 84 votes.each_value do |vs|
85 85 count = vs.select{|v| v.created_at > date}.size
86   - response.body.should have_tag"recent-votes", :text => count
  86 + response.body.should have_tag("recent-votes", :text => count)
87 87 end
88 88 end
89 89  
... ...
test/factories/density.rb
1 1 Factory.define :density do |density|
2 2 density.question_id
3 3 density.value
4   - density.type { 'string' }
  4 + density.class { 'string' }
5 5 end
... ...