Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DTT (Staging > Test) #14398

Merged
merged 2 commits into from
Apr 14, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
25 changes: 0 additions & 25 deletions bin/cron/admin_progress

This file was deleted.

16 changes: 0 additions & 16 deletions dashboard/app/controllers/admin_reports_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -150,22 +150,6 @@ def pd_progress
end
end

def admin_progress
SeamlessDatabasePool.use_persistent_read_connection do
stats = Properties.get(:admin_progress)
if stats.present?
@user_count = stats['user_count']
@levels_attempted = stats['levels_attempted']
@levels_attempted.default = 0
@levels_passed = stats['levels_passed']
@levels_passed.default = 0

@all_script_levels = Script.twenty_hour_script.script_levels.includes({level: :game})
@stage_map = @all_script_levels.group_by {|sl| sl.level.game}
end
end
end

# Use callbacks to share common setup or constraints between actions.
def set_script
@script = Script.get_from_cache(params[:script_id]) if params[:script_id]
Expand Down
38 changes: 0 additions & 38 deletions dashboard/app/views/admin_reports/admin_progress.html.haml

This file was deleted.

3 changes: 0 additions & 3 deletions dashboard/app/views/admin_reports/directory.html.haml
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
%h1 Directory of Admin Dashboards

%h3 Code Studio Progress
= link_to admin_progress_path do
Admin Progress
%br
= link_to level_completions_path do
Level Completion
%br
Expand Down
1 change: 0 additions & 1 deletion dashboard/config/routes.rb
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,6 @@ module OPS
get '/admin/levels', to: 'admin_reports#level_completions', as: 'level_completions'
get '/admin/level_answers(.:format)', to: 'admin_reports#level_answers', as: 'level_answers'
get '/admin/pd_progress(/:script)', to: 'admin_reports#pd_progress', as: 'pd_progress'
get '/admin/progress', to: 'admin_reports#admin_progress', as: 'admin_progress'
get '/admin/debug', to: 'admin_reports#debug'

# internal search tools
Expand Down
6 changes: 0 additions & 6 deletions dashboard/test/controllers/admin_reports_controller_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -7,16 +7,10 @@ class AdminReportsControllerTest < ActionController::TestCase
sign_in create(:admin)
end

generate_admin_only_tests_for :admin_progress
generate_admin_only_tests_for :debug
generate_admin_only_tests_for :directory
generate_admin_only_tests_for :level_answers

test 'should get admin progress page' do
get :admin_progress
assert_select 'h1', 'Admin progress'
end

test 'pd_progress should return 404 for unfound script' do
get :pd_progress, params: {script: 'bogus-nonexistent-script-name'}
assert_response :not_found
Expand Down