Commit 8da4bfb42b396250e3dcb5caf6e7d41866afe86c
1 parent
fdaeaf26
Exists in
master
and in
1 other branch
Activating catchup on studgov, priority marketplace
Showing
2 changed files
with
4 additions
and
2 deletions
Show diff stats
app/controllers/prompts_controller.rb
| @@ -64,7 +64,9 @@ class PromptsController < InheritedResources::Base | @@ -64,7 +64,9 @@ class PromptsController < InheritedResources::Base | ||
| 64 | #@prompt.choices.each(&:compute_score!) | 64 | #@prompt.choices.each(&:compute_score!) |
| 65 | respond_to do |format| | 65 | respond_to do |format| |
| 66 | if successful | 66 | if successful |
| 67 | - if @question.id == 120 #test0330 | 67 | + catchup_marketplace_ids = [120, 117, 1] |
| 68 | + if catchup_marketplace_ids.include?(@question.id) | ||
| 69 | + logger.info("Question #{@question.id} is using catchup algorithm!") | ||
| 68 | next_prompt = @question.catchup_choose_prompt | 70 | next_prompt = @question.catchup_choose_prompt |
| 69 | else | 71 | else |
| 70 | next_prompt = @question.picked_prompt | 72 | next_prompt = @question.picked_prompt |
lib/tasks/test_api.rake
| 1 | require 'fastercsv' | 1 | require 'fastercsv' |
| 2 | namespace :test_api do | 2 | namespace :test_api do |
| 3 | 3 | ||
| 4 | - task :all => [:question_vote_consistency] | 4 | + task :all => [:question_vote_consistency,:generate_density_information] |
| 5 | 5 | ||
| 6 | desc "Don't run unless you know what you are doing" | 6 | desc "Don't run unless you know what you are doing" |
| 7 | task(:generate_lots_of_votes => :environment) do | 7 | task(:generate_lots_of_votes => :environment) do |