diff --git a/app/api/entities/task_definition_entity.rb b/app/api/entities/task_definition_entity.rb index 04c15e74d0..042130d1b2 100644 --- a/app/api/entities/task_definition_entity.rb +++ b/app/api/entities/task_definition_entity.rb @@ -12,7 +12,8 @@ def staff?(my_role) expose :abbreviation expose :name expose :description - expose :weighting + expose :estimated_hours + expose :predicted_effort expose :target_grade with_options(format_with: :date_only) do diff --git a/app/api/task_definitions_api.rb b/app/api/task_definitions_api.rb index 8da40c69ad..7628dfd328 100644 --- a/app/api/task_definitions_api.rb +++ b/app/api/task_definitions_api.rb @@ -19,7 +19,8 @@ class TaskDefinitionsApi < Grape::API optional :tutorial_stream_abbr, type: String, desc: 'The abbreviation of tutorial stream' requires :name, type: String, desc: 'The name of this task def' requires :description, type: String, desc: 'The description of this task def' - requires :weighting, type: Integer, desc: 'The weighting of this task' + requires :estimated_hours, type: Integer, desc: 'The estimated number of hours to complete this task' + optional :predicted_effort, type: Float, desc: 'The predicted effort of the task based on task features' requires :target_grade, type: Integer, desc: 'Minimum grade for task' optional :group_set_id, type: Integer, desc: 'Related group set' requires :start_date, type: Date, desc: 'The date when the task should be started' @@ -57,7 +58,8 @@ class TaskDefinitionsApi < Grape::API .permit( :name, :description, - :weighting, + :estimated_hours, + :predicted_effort, :target_grade, :start_date, :target_date, @@ -115,7 +117,8 @@ class TaskDefinitionsApi < Grape::API optional :tutorial_stream_abbr, type: String, desc: 'The abbreviation of the tutorial stream' optional :name, type: String, desc: 'The name of this task def' optional :description, type: String, desc: 'The description of this task def' - optional :weighting, type: Integer, desc: 'The weighting of this task' + optional :estimated_hours, type: Integer, desc: 'The estimated number of hours to complete this task' + optional :predicted_effort, type: Float, desc: 'The predicted effort of the task based on task features' optional :target_grade, type: Integer, desc: 'Target grade for task' optional :group_set_id, type: Integer, desc: 'Related group set' optional :start_date, type: Date, desc: 'The date when the task should be started' @@ -171,7 +174,8 @@ class TaskDefinitionsApi < Grape::API .permit( :name, :description, - :weighting, + :estimated_hours, + :predicted_effort, :target_grade, :start_date, :target_date, @@ -926,6 +930,24 @@ class TaskDefinitionsApi < Grape::API present job, with: Entities::SidekiqJobEntity end + desc 'Predict the effort required for a task description' + params do + requires :unit_id, type: Integer, desc: 'The unit that has the task definition' + requires :task_def_id, type: Integer, desc: 'The task definition to predict effort for' + end + post '/units/:unit_id/task_definitions/:task_def_id/predict_effort' do + unit = Unit.find(params[:unit_id]) + unless authorise? current_user, unit, :get_students + error!({ error: "Not authorised to run prediction." }, 403) + end + + td = unit.task_definitions.find(params[:task_def_id]) + + PredictEffortJob.perform_async(td.id) + + present status: "Prediction queued" + end + # desc 'Retrieve the contents of the overseer execution script' # params do # requires :unit_id, type: Integer, desc: 'The unit that has the task definition' diff --git a/app/models/project.rb b/app/models/project.rb index 1444730f9b..2c50c28e4e 100644 --- a/app/models/project.rb +++ b/app/models/project.rb @@ -464,7 +464,7 @@ def discuss_and_demonstrate_tasks # get the weight of all tasks completed or marked as ready to assess # def completed_tasks_weight - ready_or_complete_tasks.empty? ? 0.0 : ready_or_complete_tasks.map { |task| task.task_definition.weighting }.inject(:+) + ready_or_complete_tasks.empty? ? 0.0 : ready_or_complete_tasks.map { |task| task.task_definition.estimated_hours }.inject(:+) end def convert_hash_to_pct(hash, total) @@ -594,7 +594,7 @@ def assigned_task_defs end def total_task_weight - assigned_task_defs.map(&:weighting).inject(:+) + assigned_task_defs.map(&:estimated_hours).inject(:+) end def remaining_days diff --git a/app/models/task.rb b/app/models/task.rb index ee3e76564c..a15c6d4e54 100644 --- a/app/models/task.rb +++ b/app/models/task.rb @@ -837,7 +837,7 @@ def assessed? end def weight - task_definition.weighting.to_f + task_definition.estimated_hours.to_f end def add_text_comment(user, text, reply_to_id = nil) diff --git a/app/models/task_definition.rb b/app/models/task_definition.rb index 8d2fa7c5cd..6effea69eb 100644 --- a/app/models/task_definition.rb +++ b/app/models/task_definition.rb @@ -104,7 +104,7 @@ def self.permissions validate :unit_must_be_same validate :tutorial_stream_present? - validates :weighting, presence: true + validates :estimated_hours, presence: true validate :check_existing_prerequisites @@ -542,7 +542,7 @@ def to_csv_row end def self.csv_columns - [:name, :abbreviation, :description, :weighting, :target_grade, :restrict_status_updates, :max_quality_pts, + [:name, :abbreviation, :description, :estimated_hours, :target_grade, :restrict_status_updates, :max_quality_pts, :is_graded, :plagiarism_warn_pct, :scorm_enabled, :scorm_allow_review, :scorm_bypass_test, :scorm_time_delay_enabled, :scorm_attempt_limit, :group_set, :upload_requirements, :start_week, :start_day, :target_week, :target_day, :due_week, :due_day, :tutorial_stream, :assess_in_portfolio_only, :task_prerequisites, :discussion_prompts] @@ -572,7 +572,7 @@ def self.task_def_for_csv_row(unit, row) result = TaskDefinition.find_or_create_by(unit_id: unit.id, tutorial_stream: tutorial_stream, name: name, abbreviation: abbreviation) do |td| td.target_date = target_date td.start_date = start_date - td.weighting = row[:weighting].to_i + td.estimated_hours = row[:estimated_hours].to_i end new_task = true end @@ -581,7 +581,7 @@ def self.task_def_for_csv_row(unit, row) result.unit_id = unit.id result.abbreviation = abbreviation result.description = "#{row[:description]}".strip - result.weighting = row[:weighting].to_i + result.estimated_hours = row[:estimated_hours].to_i result.target_grade = row[:target_grade].to_i result.restrict_status_updates = %w(Yes y Y yes true TRUE 1).include? "#{row[:restrict_status_updates]}".strip result.max_quality_pts = row[:max_quality_pts].to_i diff --git a/app/sidekiq/predict_effort_job.rb b/app/sidekiq/predict_effort_job.rb new file mode 100644 index 0000000000..972b5a47c6 --- /dev/null +++ b/app/sidekiq/predict_effort_job.rb @@ -0,0 +1,33 @@ +require "net/http" +require "json" + +class PredictEffortJob + include Sidekiq::Worker + + def perform(task_def_id) + td = TaskDefinition.find(task_def_id) + payload = build_payload(td) + Rails.logger.info("ML payload: #{payload.to_json}") + response = Net::HTTP.post( + URI("#{ENV.fetch('ML_SERVICE_URL')}predict"), + payload.to_json, + "Content-Type" => "application/json" + ) + + result = JSON.parse(response.body) + Rails.logger.info("FastAPI response: #{response.body}") + td.update(predicted_effort: result["predicted_effort"]) + end + + private + + def build_payload(task_def) + { + estimated_hours: task_def.estimated_hours, + target_grade: task_def.target_grade, + start_date: task_def.start_date, + due_date: task_def.due_date # , + # TODO: task sheet for TF-IDF + } + end +end diff --git a/db/migrate/20260425091151_change_weighting_to_estimated_hours_in_task_definitions.rb b/db/migrate/20260425091151_change_weighting_to_estimated_hours_in_task_definitions.rb new file mode 100644 index 0000000000..f56e8a7d61 --- /dev/null +++ b/db/migrate/20260425091151_change_weighting_to_estimated_hours_in_task_definitions.rb @@ -0,0 +1,5 @@ +class ChangeWeightingToEstimatedHoursInTaskDefinitions < ActiveRecord::Migration[8.0] + def change + rename_column :task_definitions, :weighting, :estimated_hours + end +end diff --git a/db/migrate/20260425165056_add_predicted_effort_to_tasks.rb b/db/migrate/20260425165056_add_predicted_effort_to_tasks.rb new file mode 100644 index 0000000000..33c40ce6a6 --- /dev/null +++ b/db/migrate/20260425165056_add_predicted_effort_to_tasks.rb @@ -0,0 +1,5 @@ +class AddPredictedEffortToTasks < ActiveRecord::Migration[8.0] + def change + add_column :task_definitions, :predicted_effort, :float + end +end diff --git a/db/migrate/20260426101725_set_default_predicted_effort_on_task_definitions.rb b/db/migrate/20260426101725_set_default_predicted_effort_on_task_definitions.rb new file mode 100644 index 0000000000..e7f53d2235 --- /dev/null +++ b/db/migrate/20260426101725_set_default_predicted_effort_on_task_definitions.rb @@ -0,0 +1,10 @@ +class SetDefaultPredictedEffortOnTaskDefinitions < ActiveRecord::Migration[8.0] + def up + change_column_default :task_definitions, :predicted_effort, 1.0 + TaskDefinition.where(predicted_effort: nil).update_all(predicted_effort: 1.0) + end + + def down + change_column_default :task_definitions, :predicted_effort, nil + end +end diff --git a/db/schema.rb b/db/schema.rb index 73fc5ebd58..3fc9a273f2 100644 --- a/db/schema.rb +++ b/db/schema.rb @@ -10,7 +10,7 @@ # # It's strongly recommended that you check this file into your version control system. -ActiveRecord::Schema[8.0].define(version: 2026_03_22_230239) do +ActiveRecord::Schema[8.0].define(version: 2026_04_26_101725) do create_table "activity_types", charset: "utf8mb4", collation: "utf8mb4_general_ci", force: :cascade do |t| t.string "name", null: false t.string "abbreviation", null: false @@ -420,7 +420,7 @@ t.bigint "unit_id" t.string "name" t.string "description", limit: 4096 - t.decimal "weighting", precision: 10 + t.decimal "estimated_hours", precision: 10 t.datetime "target_date", null: false t.datetime "created_at", null: false t.datetime "updated_at", null: false @@ -450,6 +450,7 @@ t.boolean "use_resources_for_jplag_base_code", default: false, null: false t.boolean "lock_assessments_to_tutorial_stream", default: false, null: false t.boolean "requires_discussion", default: false, null: false + t.float "predicted_effort", default: 1.0 t.index ["abbreviation", "unit_id"], name: "index_task_definitions_on_abbreviation_and_unit_id", unique: true t.index ["group_set_id"], name: "index_task_definitions_on_group_set_id" t.index ["name", "unit_id"], name: "index_task_definitions_on_name_and_unit_id", unique: true diff --git a/lib/helpers/database_populator.rb b/lib/helpers/database_populator.rb index 57911a98bc..49e5cb7de7 100644 --- a/lib/helpers/database_populator.rb +++ b/lib/helpers/database_populator.rb @@ -670,7 +670,7 @@ def generate_tasks_for_unit(unit, unit_details) abbreviation: "A#{count + 1}", unit_id: unit.id, description: faker_random_sentence(5, 10), - weighting: BigDecimal("2"), + estimated_hours: BigDecimal("2"), target_date: target_date, upload_requirements: up_reqs, start_date: start_date, diff --git a/lib/tasks/simulate_jplag_submissions.rake b/lib/tasks/simulate_jplag_submissions.rake index 33c1a8975c..85e9d3063e 100644 --- a/lib/tasks/simulate_jplag_submissions.rake +++ b/lib/tasks/simulate_jplag_submissions.rake @@ -27,7 +27,7 @@ namespace :db do unit_id: unit.id, tutorial_stream: unit.tutorial_streams.first, description: faker_random_sentence(5, 10), - weighting: BigDecimal("2"), + estimated_hours: BigDecimal("2"), target_date: target_date, upload_requirements: [ { diff --git a/test/api/comments/comment_test.rb b/test/api/comments/comment_test.rb index 1e1fc558a1..91b1efe54f 100644 --- a/test/api/comments/comment_test.rb +++ b/test/api/comments/comment_test.rb @@ -241,7 +241,7 @@ def test_student_reply_to_other_student_in_same_group tutorial_stream: unit.tutorial_streams.first, name: 'Task to switch from ind to group after submission', description: 'test def', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 1.week, target_date: Time.zone.now - 1.day, @@ -484,7 +484,7 @@ def test_read_receipts_for_task_status_comments tutorial_stream: unit.tutorial_streams.first, name: 'test_read_receipts_for_task_status_comments', description: 'test_read_receipts_for_task_status_comments', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now + 1.week, @@ -527,7 +527,7 @@ def test_project_plan_task_comments_dont_show_in_inbox tutorial_stream: unit.tutorial_streams.first, name: 'test_project_plan_task_comments_dont_show_in_inbox', description: 'test_project_plan_task_comments_dont_show_in_inbox', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now + 1.week, @@ -574,7 +574,7 @@ def test_discussed_in_class_task_comments_dont_show_in_inbox tutorial_stream: unit.tutorial_streams.first, name: 'test_discussed_in_class_task_comments_dont_show_in_inbox', description: 'test_discussed_in_class_task_comments_dont_show_in_inbox', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now + 1.week, diff --git a/test/api/comments/extension_test.rb b/test/api/comments/extension_test.rb index 7c707ab798..eaa3f06d52 100644 --- a/test/api/comments/extension_test.rb +++ b/test/api/comments/extension_test.rb @@ -19,7 +19,7 @@ def test_extension_application tutorial_stream: project.tutorial_enrolments.first.tutorial.tutorial_stream, name: 'status task change', description: 'status task change test', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now - 1.day, @@ -94,7 +94,7 @@ def test_extension_application tutorial_stream: unit.tutorial_streams.first, name: 'status task change', description: 'status task change test', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now - 1.day, @@ -152,7 +152,7 @@ def test_disallow_student_extensions tutorial_stream: unit.tutorial_streams.first, name: 'status task change', description: 'status task change test', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now - 1.day, @@ -201,7 +201,7 @@ def test_extension_on_resubmit tutorial_stream: unit.tutorial_streams.first, name: 'Task past due - for revert', description: 'Task past due', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now + 1.day, @@ -257,7 +257,7 @@ def test_extension_in_inbox tutorial_stream: unit.tutorial_streams.first, name: 'status task change', description: 'status task change test', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now - 1.day, @@ -317,7 +317,7 @@ def test_flexible_dates tutorial_stream: unit.tutorial_streams.first, name: 'Flexible Dates Test', description: 'Flexible Dates Test', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now + 1.day, diff --git a/test/api/comments/scorm_extension_test.rb b/test/api/comments/scorm_extension_test.rb index f206b8f0f5..cafaffdc1b 100644 --- a/test/api/comments/scorm_extension_test.rb +++ b/test/api/comments/scorm_extension_test.rb @@ -20,7 +20,7 @@ def test_scorm_extension_request tutorial_stream: unit.tutorial_streams.first, name: 'Scorm extension request', description: 'Scorm extension request', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now - 1.week, @@ -82,7 +82,7 @@ def test_read_by_main_tutor tutorial_stream: unit.tutorial_streams.first, name: 'Scorm extension request', description: 'Scorm extension request', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now - 1.week, @@ -138,7 +138,7 @@ def test_auto_grant_for_tutor tutorial_stream: unit.tutorial_streams.first, name: 'Scorm extension request', description: 'Scorm extension request', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now - 1.week, @@ -188,7 +188,7 @@ def test_scorm_extension_assessment tutorial_stream: unit.tutorial_streams.first, name: 'Scorm extension', description: 'Scorm extension', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now - 1.week, diff --git a/test/api/comments/status_test.rb b/test/api/comments/status_test.rb index 9c2e729b12..51de89d48b 100644 --- a/test/api/comments/status_test.rb +++ b/test/api/comments/status_test.rb @@ -20,7 +20,7 @@ def test_status_comments abbreviation: 'test_status_comments', name: 'test_status_comments', description: 'test_status_comments', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now - 1.week, diff --git a/test/api/groups_api_test.rb b/test/api/groups_api_test.rb index 9c71389519..24336cc64a 100644 --- a/test/api/groups_api_test.rb +++ b/test/api/groups_api_test.rb @@ -33,7 +33,7 @@ def test_group_submission_with_extensions tutorial_stream: unit.tutorial_streams.first, name: 'Task to switch from ind to group after submission', description: 'test def', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 1.week, target_date: Time.zone.now - 1.day, @@ -99,7 +99,7 @@ def test_comment_on_group_task_without_group tutorial_stream: unit.tutorial_streams.first, name: 'Task to switch from ind to group after submission', description: 'test def', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 1.week, target_date: Time.zone.now - 1.day, @@ -146,7 +146,7 @@ def test_pdf_comment_on_group_task tutorial_stream: unit.tutorial_streams.first, name: 'Task to switch from ind to group after submission', description: 'test def', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 1.week, target_date: Time.zone.now - 1.day, @@ -189,7 +189,7 @@ def test_pdf_comment_on_group_task_without_group tutorial_stream: unit.tutorial_streams.first, name: 'Task to switch from ind to group after submission', description: 'test def', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 1.week, target_date: Time.zone.now - 1.day, diff --git a/test/api/scorm_api_test.rb b/test/api/scorm_api_test.rb index 22287d1888..bb75f8cf97 100644 --- a/test/api/scorm_api_test.rb +++ b/test/api/scorm_api_test.rb @@ -26,7 +26,7 @@ def test_serve_scorm_content tutorial_stream: unit.tutorial_streams.first, name: 'Task scorm', description: 'Task with scorm test', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now - 1.week, diff --git a/test/api/tasks_api_test.rb b/test/api/tasks_api_test.rb index 4d2f996016..14a03e0cb3 100644 --- a/test/api/tasks_api_test.rb +++ b/test/api/tasks_api_test.rb @@ -50,7 +50,7 @@ def test_get_task_submission_details_creates_session_and_activity tutorial_stream: unit.tutorial_streams.first, name: 'Task past due - for revert', description: 'Task past due', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now - 1.week, @@ -146,7 +146,7 @@ def test_time_exceeded_grade tutorial_stream: unit.tutorial_streams.first, name: 'Task past due', description: 'Task past due', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now - 1.week, @@ -186,7 +186,7 @@ def test_extension_reverts_time_exceeded tutorial_stream: unit.tutorial_streams.first, name: 'Task past due - for revert', description: 'Task past due', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now - 1.week, @@ -264,7 +264,7 @@ def test_extension_reverts_time_exceeded_auto_apply tutorial_stream: unit.tutorial_streams.first, name: 'Task past due - for revert', description: 'Task past due', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now - 1.week, @@ -438,7 +438,7 @@ def test_can_submit_ipynb tutorial_stream: unit.tutorial_streams.first, name: 'Code task', description: 'Code task', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now + 1.week, @@ -479,7 +479,7 @@ def test_invalid_latex_in_ipynb tutorial_stream: unit.tutorial_streams.first, name: 'Code task', description: 'Code task', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now + 1.week, @@ -520,7 +520,7 @@ def test_download_task_pdf tutorial_stream: unit.tutorial_streams.first, name: 'Code task', description: 'Code task', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now + 1.week, @@ -778,7 +778,7 @@ def test_check_in_comment tutorial_stream: unit.tutorial_streams.first, name: 'Code task', description: 'Code task', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now + 1.week, @@ -826,7 +826,7 @@ def test_requires_discussion_blocks_complete_until_discussed_comment_added tutorial_stream: unit.tutorial_streams.first, name: 'Discussion required task', description: 'Task that requires discussion before complete', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now + 1.week, diff --git a/test/api/test_attempts_test.rb b/test/api/test_attempts_test.rb index be0c02ae5e..4ace1f4ac5 100644 --- a/test/api/test_attempts_test.rb +++ b/test/api/test_attempts_test.rb @@ -20,7 +20,7 @@ def test_get_task_attempts tutorial_stream: unit.tutorial_streams.first, name: 'Test attempts', description: 'Test attempts', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now - 1.week, @@ -53,7 +53,7 @@ def test_get_task_attempts tutorial_stream: unit.tutorial_streams.first, name: 'Test attempts new', description: 'Test attempts new', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now - 1.week, @@ -108,7 +108,7 @@ def test_get_latest tutorial_stream: unit.tutorial_streams.first, name: 'Test attempts', description: 'Test attempts', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now - 1.week, @@ -177,7 +177,7 @@ def test_review_attempt tutorial_stream: unit.tutorial_streams.first, name: 'Test attempts', description: 'Test attempts', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now - 1.week, @@ -273,7 +273,7 @@ def test_post_attempt tutorial_stream: unit.tutorial_streams.first, name: 'Test attempts', description: 'Test attempts', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now - 1.week, @@ -358,7 +358,7 @@ def test_update_attempt tutorial_stream: unit.tutorial_streams.first, name: 'Test attempts', description: 'Test attempts', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now - 1.week, @@ -452,7 +452,7 @@ def test_delete_attempt tutorial_stream: unit.tutorial_streams.first, name: 'Test attempts', description: 'Test attempts', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now - 1.week, diff --git a/test/api/unit_roles_test.rb b/test/api/unit_roles_test.rb index 5e24941fd0..d66bbcac70 100644 --- a/test/api/unit_roles_test.rb +++ b/test/api/unit_roles_test.rb @@ -220,7 +220,7 @@ def test_observer_unit_role task_def: { name: "Sample Task", description: "This is a test task", - weighting: 10, + estimated_hours: 10, target_grade: 50, start_date: Time.zone.today, target_date: Time.zone.today + 7.days, diff --git a/test/api/units/feedback_test.rb b/test/api/units/feedback_test.rb index 1b51591544..bb03ac6a2d 100644 --- a/test/api/units/feedback_test.rb +++ b/test/api/units/feedback_test.rb @@ -40,7 +40,7 @@ def test_tasks_for_task_inbox tutorial_stream: unit.tutorial_streams.first, name: 'Code task', description: 'Code task', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now + 1.week, @@ -57,7 +57,7 @@ def test_tasks_for_task_inbox tutorial_stream: unit.tutorial_streams.first, name: 'Code task2', description: 'Code task2', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now + 1.week, diff --git a/test/api/units/task_definitions_api_test.rb b/test/api/units/task_definitions_api_test.rb index 00967f32b0..73a3bfb6e4 100644 --- a/test/api/units/task_definitions_api_test.rb +++ b/test/api/units/task_definitions_api_test.rb @@ -38,7 +38,7 @@ def test_task_definition_cud tutorial_stream_abbr: unit.tutorial_streams.first.abbreviation, name: 'New Task Def', description: 'First task def', - weighting: 4, + estimated_hours: 4, target_grade: 1, group_set_id: unit.group_sets.first.id, start_date: unit.start_date, @@ -65,14 +65,14 @@ def test_task_definition_cud assert_json_matches_model td, last_response_body, all_task_def_keys assert_equal [{ "key" => "file0", "name" => "Shape Class", "type" => "document" }], td.upload_requirements assert_equal unit.tutorial_streams.first.id, td.tutorial_stream_id - assert_equal 4, td.weighting + assert_equal 4, td.estimated_hours data_to_put = { task_def: { tutorial_stream_abbr: unit.tutorial_streams.last.abbreviation, name: 'New Task Def 1', description: 'First task def 1', - weighting: 2, + estimated_hours: 2, target_grade: 2, group_set_id: nil, start_date: unit.start_date + 2.days, @@ -98,7 +98,7 @@ def test_task_definition_cud assert_json_matches_model td, last_response_body, all_task_def_keys assert_equal unit.tutorial_streams.last.id, td.tutorial_stream_id assert_equal [{ "key" => "file0", "name" => "Other Class", "type" => "document" }], td.upload_requirements - assert_equal 2, td.weighting + assert_equal 2, td.estimated_hours end def test_post_invalid_file_tasksheet @@ -245,7 +245,7 @@ def test_submission_creates_folders tutorial_stream: unit.tutorial_streams.first, name: 'test_submission_creates_folders', description: 'test def', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: unit.start_date + 1.week, target_date: unit.start_date + 2.weeks, @@ -299,7 +299,7 @@ def test_change_to_group_after_submissions tutorial_stream: unit.tutorial_streams.first, name: 'Task to switch from ind to group after submission', description: 'test def', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: unit.start_date + 1.week, target_date: unit.start_date + 2.weeks, diff --git a/test/factories/units_factory.rb b/test/factories/units_factory.rb index 7cc6de1090..b8cb0c3550 100644 --- a/test/factories/units_factory.rb +++ b/test/factories/units_factory.rb @@ -11,7 +11,7 @@ upload_requirements { [{'key' => 'file0','name' => 'Imported Code','type' => 'code'}] } start_date { unit.start_date + rand(1..12).weeks } sequence(:abbreviation) { |n| "#{GradeHelper.short_grade_for target_grade}#{((unit.start_date - start_date) / 1.week).floor + 1}.#{n}" } - weighting { rand(1..5) } + estimated_hours { rand(1..5) } target_date { start_date + rand(1..2).weeks } group_set { nil } tutorial_stream { unit.tutorial_streams.sample } diff --git a/test/models/group_test.rb b/test/models/group_test.rb index 3a9cfad589..27bf9ff902 100644 --- a/test/models/group_test.rb +++ b/test/models/group_test.rb @@ -150,7 +150,7 @@ def test_submit_with_others_having_extensions tutorial_stream: unit.tutorial_streams.first, name: 'Task for test', description: 'test def', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now + 3.days, target_date: Time.zone.now + 1.week, diff --git a/test/models/task_definition_test.rb b/test/models/task_definition_test.rb index 77f9d9ed5f..9f1c26cfe2 100644 --- a/test/models/task_definition_test.rb +++ b/test/models/task_definition_test.rb @@ -15,7 +15,7 @@ def test_default_quality_points tutorial_stream: test_unit.tutorial_streams.first, name: 'Test quality points', description: 'test def', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: test_unit.start_date + 1.week, target_date: test_unit.start_date + 2.weeks, @@ -45,7 +45,7 @@ def test_default_tii_settings tutorial_stream: test_unit.tutorial_streams.first, name: 'Test tii settings', description: 'test def', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: test_unit.start_date + 1.week, target_date: test_unit.start_date + 2.weeks, diff --git a/test/models/task_status_test.rb b/test/models/task_status_test.rb index e5081c59d3..9ac5b4f62a 100644 --- a/test/models/task_status_test.rb +++ b/test/models/task_status_test.rb @@ -21,7 +21,7 @@ def test_status_chanaged_with_extenssion unit_id: unit.id, name: 'Task past due - for revert', description: 'Task past due', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now - 1.week, @@ -69,7 +69,7 @@ def test_status_changed_task_definition_assess_in_portfolio_only unit_id: unit.id, name: 'Task past due - for revert', description: 'Task past due', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now - 1.week, @@ -118,7 +118,7 @@ def test_status_changed_unit_has_assess_in_portfolio_tasks unit_id: unit.id, name: 'Task past due - for revert', description: 'Task past due', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now - 1.week, @@ -164,7 +164,7 @@ def test_tutor_cant_signoff_tasks_complete_assess_in_portfolio_only unit_id: unit.id, name: 'Task past due - for revert', description: 'Task past due', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now + 1.week, @@ -227,7 +227,7 @@ def test_tutor_can_update_assess_in_portfolio_tasks_to_working_on_it unit_id: unit.id, name: 'Task past due - for revert', description: 'Task past due', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now + 1.week, @@ -275,7 +275,7 @@ def test_student_cant_update_assess_in_portfolio_without_files unit_id: unit.id, name: 'Task past due - for revert', description: 'Task past due', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now + 1.week, @@ -335,7 +335,7 @@ def test_student_cant_update_assess_in_portfolio_if_task_def_not_aip unit_id: unit.id, name: 'Task past due - for revert', description: 'Task past due', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 2.weeks, target_date: Time.zone.now + 1.week, @@ -394,7 +394,7 @@ def test_submission_for_assess_in_portfolio tutorial_stream: unit.tutorial_streams.first, name: 'Task with image2', description: 'img task2', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: unit.start_date + 1.week, target_date: unit.start_date + 2.weeks, @@ -435,7 +435,7 @@ def test_assess_in_portfolio_submissions_dont_show_in_tutor_inbox tutorial_stream: unit.tutorial_streams.first, name: 'Task with image2', description: 'img task2', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: unit.start_date + 1.week, target_date: unit.start_date + 2.weeks, diff --git a/test/models/task_test.rb b/test/models/task_test.rb index cab193b681..c31e8b95c5 100644 --- a/test/models/task_test.rb +++ b/test/models/task_test.rb @@ -55,7 +55,7 @@ def test_pdf_creation_with_gif tutorial_stream: unit.tutorial_streams.first, name: 'Task with image', description: 'img task', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: unit.start_date + 1.week, target_date: unit.start_date + 2.weeks, @@ -100,7 +100,7 @@ def test_image_upload tutorial_stream: unit.tutorial_streams.first, name: 'Task with image2', description: 'img task2', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: unit.start_date + 1.week, target_date: unit.start_date + 2.weeks, @@ -142,7 +142,7 @@ def test_pdf_creation_with_jpg tutorial_stream: unit.tutorial_streams.first, name: 'Task with image', description: 'img task', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: unit.start_date + 1.week, target_date: unit.start_date + 2.weeks, @@ -187,7 +187,7 @@ def test_pdf_with_quotes_in_task_title tutorial_stream: unit.tutorial_streams.first, name: '"Quoted Task"', description: 'Task with quotes in name', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: unit.start_date + 1.week, target_date: unit.start_date + 2.weeks, @@ -333,7 +333,7 @@ def test_ipynb_to_pdf tutorial_stream: unit.tutorial_streams.first, name: 'Task with ipynb', description: 'Code task', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: unit.start_date + 1.week, target_date: unit.start_date + 2.weeks, @@ -431,7 +431,7 @@ def test_code_submission_with_long_lines tutorial_stream: unit.tutorial_streams.first, name: 'Task with super ling lines in code submission', description: 'Code task', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: unit.start_date + 1.week, target_date: unit.start_date + 2.weeks, @@ -505,7 +505,7 @@ def test_code_submission_with_long_lines tutorial_stream: unit.tutorial_streams.first, name: 'Task with super ling lines in code submission', description: 'Code task', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: unit.start_date + 1.week, target_date: unit.start_date + 2.weeks, @@ -579,7 +579,7 @@ def test_code_submission_with_long_lines tutorial_stream: unit.tutorial_streams.first, name: 'Task with super ling lines in code submission', description: 'Code task', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: unit.start_date + 1.week, target_date: unit.start_date + 2.weeks, @@ -653,7 +653,7 @@ def test_pdf_validation_on_submit tutorial_stream: unit.tutorial_streams.first, name: 'PDF Test Task', description: 'Test task', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: unit.start_date + 1.week, target_date: unit.start_date + 2.weeks, @@ -722,7 +722,7 @@ def test_pdf_creation_fails_on_invalid_pdf tutorial_stream: unit.tutorial_streams.first, name: 'PDF Test Task', description: 'Test task', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: unit.start_date + 1.week, target_date: unit.start_date + 2.weeks, @@ -769,7 +769,7 @@ def test_pax_crash_does_not_stop_pdf_creation tutorial_stream: unit.tutorial_streams.first, name: 'PDF Test Task', description: 'Test task', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: unit.start_date + 1.week, target_date: unit.start_date + 2.weeks, @@ -1099,7 +1099,7 @@ def test_portfolio_evidence_path tutorial_stream: unit.tutorial_streams.first, name: 'Test task', description: 'Code task', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: unit.start_date + 1.week, target_date: unit.start_date + 2.weeks, @@ -1206,7 +1206,7 @@ def test_extension_on_trigger_transition tutorial_stream: unit.tutorial_streams.first, name: 'Test task', description: 'Test task', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: unit.start_date, target_date: unit.start_date + 1.week, @@ -1262,7 +1262,7 @@ def test_trigger_time_exceeded tutorial_stream: unit.tutorial_streams.first, name: 'Test task', description: 'Test task', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 3.week, target_date: Time.zone.now - 2.week, @@ -1347,7 +1347,7 @@ def test_assessment_lock_to_tutorial_stream tutorial_stream: tutorial_stream_main, name: 'Test task for main', description: 'Test task', - weighting: 4, + estimated_hours: 4, target_grade: 0, start_date: Time.zone.now - 3.weeks, target_date: Time.zone.now - 2.weeks, @@ -1366,7 +1366,7 @@ def test_assessment_lock_to_tutorial_stream tutorial_stream: tutorial_stream_hd, name: 'Test task for HD', description: 'Test task', - weighting: 4, + estimated_hours: 4, target_grade: 3, start_date: Time.zone.now - 3.weeks, target_date: Time.zone.now - 2.weeks, diff --git a/test_files/COS10001-ImportTasksWithTutorialStream.csv b/test_files/COS10001-ImportTasksWithTutorialStream.csv index bc92146d61..80b23df923 100644 --- a/test_files/COS10001-ImportTasksWithTutorialStream.csv +++ b/test_files/COS10001-ImportTasksWithTutorialStream.csv @@ -1,4 +1,4 @@ -name,abbreviation,description,weighting,target_grade,restrict_status_updates,upload_requirements,start_week,start_day,target_week,target_day,due_week,due_day,max_quality_pts,is_graded,plagiarism_warn_pct,plagiarism_checks,group_set,tutorial_stream,scorm_enabled,scorm_allow_review,scorm_bypass_test,scorm_time_delay_enabled,scorm_attempt_limit,assess_in_portfolio_only,task_prerequisites,discussion_prompts +name,abbreviation,description,estimated_hours,target_grade,restrict_status_updates,upload_requirements,start_week,start_day,target_week,target_day,due_week,due_day,max_quality_pts,is_graded,plagiarism_warn_pct,plagiarism_checks,group_set,tutorial_stream,scorm_enabled,scorm_allow_review,scorm_bypass_test,scorm_time_delay_enabled,scorm_attempt_limit,assess_in_portfolio_only,task_prerequisites,discussion_prompts Pass Task 1.1 - Hello World,1.1P,"As a first step, create the classic 'Hello World' program. This will help ensure that you have all of the software installed correctly, and are ready to move on with creating other,,, programs.",1,0,FALSE,"[{""key"":""file0"",""name"":""HelloWorld.pas"",""type"":""code""},{""key"":""file1"",""name"":""Screenshot"",""type"":""image""}]",1,Tue,2,Tue,5,Mon,0,FALSE,90,,,import-tasks,,,,FALSE,[],[] Pass Task 1.2 - Picture Drawing,1.2P,Create a program that calls procedures to draw a picture to a window (something other than a house which we use as the example).,2,0,FALSE,"[{""key"":""file0"",""name"":""PictureDrawing.pas"",""type"":""code""},{""key"":""file1"",""name"":""Screenshot"",""type"":""image""}]",1,Tue,2,Tue,5,Mon,0,FALSE,90,,,import-tasks,,,,FALSE,[],[] Pass Task 1.3 - Creating a Procedure,1.3P,"Now that you have created a program that uses procedures, you can learn how to create your own procedures. Creating procedures will allow you to group your program's actions into procedures that perform meaningful tasks.",2,0,FALSE,"[{""key"":""file0"",""name"":""PictureDrawing.pas"",""type"":""code""},{""key"":""file1"",""name"":""Screenshot"",""type"":""image""}]",1,Tue,2,Tue,5,Mon,0,FALSE,90,,,import-tasks,,,,FALSE,[],[] diff --git a/test_files/COS10001-ImportTasksWithoutTutorialStream.csv b/test_files/COS10001-ImportTasksWithoutTutorialStream.csv index a5e4a89700..d51c1e5f6e 100644 --- a/test_files/COS10001-ImportTasksWithoutTutorialStream.csv +++ b/test_files/COS10001-ImportTasksWithoutTutorialStream.csv @@ -1,4 +1,4 @@ -name,abbreviation,description,weighting,target_grade,restrict_status_updates,upload_requirements,start_week,start_day,target_week,target_day,due_week,due_day,max_quality_pts,is_graded,plagiarism_warn_pct,plagiarism_checks,group_set,tutorial_stream,scorm_enabled,scorm_allow_review,scorm_bypass_test,scorm_time_delay_enabled,scorm_attempt_limit,assess_in_portfolio_only,task_prerequisites,discussion_prompts +name,abbreviation,description,estimated_hours,target_grade,restrict_status_updates,upload_requirements,start_week,start_day,target_week,target_day,due_week,due_day,max_quality_pts,is_graded,plagiarism_warn_pct,plagiarism_checks,group_set,tutorial_stream,scorm_enabled,scorm_allow_review,scorm_bypass_test,scorm_time_delay_enabled,scorm_attempt_limit,assess_in_portfolio_only,task_prerequisites,discussion_prompts Pass Task 1.1 - Hello World,1.1P,"As a first step, create the classic 'Hello World' program. This will help ensure that you have all of the software installed correctly, and are ready to move on with creating other,,, programs.",1,0,FALSE,"[{""key"":""file0"",""name"":""HelloWorld.pas"",""type"":""code""},{""key"":""file1"",""name"":""Screenshot"",""type"":""image""}]",1,Tue,2,Tue,5,Mon,0,FALSE,90,,,,,,,FALSE,[],[] Pass Task 1.2 - Picture Drawing,1.2P,Create a program that calls procedures to draw a picture to a window (something other than a house which we use as the example).,2,0,FALSE,"[{""key"":""file0"",""name"":""PictureDrawing.pas"",""type"":""code""},{""key"":""file1"",""name"":""Screenshot"",""type"":""image""}]",1,Tue,2,Tue,5,Mon,0,FALSE,90,,,,,,,FALSE,[],[] Pass Task 1.3 - Creating a Procedure,1.3P,"Now that you have created a program that uses procedures, you can learn how to create your own procedures. Creating procedures will allow you to group your program's actions into procedures that perform meaningful tasks.",2,0,FALSE,"[{""key"":""file0"",""name"":""PictureDrawing.pas"",""type"":""code""},{""key"":""file1"",""name"":""Screenshot"",""type"":""image""}]",1,Tue,2,Tue,5,Mon,0,FALSE,90,,,,,,,FALSE,[],[] diff --git a/test_files/COS10001-Tasks.csv b/test_files/COS10001-Tasks.csv index 54036fe3c2..54aaa32c4b 100644 --- a/test_files/COS10001-Tasks.csv +++ b/test_files/COS10001-Tasks.csv @@ -1,4 +1,4 @@ -name,abbreviation,description,weighting,target_grade,restrict_status_updates,upload_requirements,start_week,start_day,target_week,target_day,due_week,due_day,max_quality_pts,is_graded,plagiarism_warn_pct,plagiarism_checks,group_set,tutorial_stream,scorm_enabled,scorm_allow_review,scorm_bypass_test,scorm_time_delay_enabled,scorm_attempt_limit,assess_in_portfolio_only,task_prerequisites,discussion_prompts +name,abbreviation,description,estimated_hours,target_grade,restrict_status_updates,upload_requirements,start_week,start_day,target_week,target_day,due_week,due_day,max_quality_pts,is_graded,plagiarism_warn_pct,plagiarism_checks,group_set,tutorial_stream,scorm_enabled,scorm_allow_review,scorm_bypass_test,scorm_time_delay_enabled,scorm_attempt_limit,assess_in_portfolio_only,task_prerequisites,discussion_prompts Pass Task 1.1 - Hello World,1.1P,"As a first step, create the classic 'Hello World' program. This will help ensure that you have all of the software installed correctly, and are ready to move on with creating other,,, programs.",1,0,FALSE,"[{""key"":""file0"",""name"":""HelloWorld.pas"",""type"":""code""},{""key"":""file1"",""name"":""Screenshot"",""type"":""image""}]",1,Tue,2,Tue,5,Mon,0,FALSE,90,,,import-tasks,FALSE,[],[] Pass Task 1.2 - Picture Drawing,1.2P,Create a program that calls procedures to draw a picture to a window (something other than a house which we use as the example).,2,0,FALSE,"[{""key"":""file0"",""name"":""PictureDrawing.pas"",""type"":""code""},{""key"":""file1"",""name"":""Screenshot"",""type"":""image""}]",1,Tue,2,Tue,5,Mon,0,FALSE,90,,,import-tasks,FALSE,[],[] Pass Task 1.3 - Creating a Procedure,1.3P,"Now that you have created a program that uses procedures, you can learn how to create your own procedures. Creating procedures will allow you to group your program's actions into procedures that perform meaningful tasks.",2,0,FALSE,"[{""key"":""file0"",""name"":""PictureDrawing.pas"",""type"":""code""},{""key"":""file1"",""name"":""Screenshot"",""type"":""image""}]",1,Tue,2,Tue,5,Mon,0,FALSE,90,,,import-tasks,FALSE,[],[] diff --git a/test_files/COS10001-TasksUnorderedUploadReqs.csv b/test_files/COS10001-TasksUnorderedUploadReqs.csv index 7a4d27adc4..806404fe26 100644 --- a/test_files/COS10001-TasksUnorderedUploadReqs.csv +++ b/test_files/COS10001-TasksUnorderedUploadReqs.csv @@ -1,4 +1,4 @@ -name,abbreviation,description,weighting,target_grade,restrict_status_updates,upload_requirements,start_week,start_day,target_week,target_day,due_week,due_day,max_quality_pts,is_graded,plagiarism_warn_pct,plagiarism_checks,group_set,tutorial_stream,scorm_enabled,scorm_allow_review,scorm_bypass_test,scorm_time_delay_enabled,scorm_attempt_limit,assess_in_portfolio_only,task_prerequisites,discussion_prompts +name,abbreviation,description,estimated_hours,target_grade,restrict_status_updates,upload_requirements,start_week,start_day,target_week,target_day,due_week,due_day,max_quality_pts,is_graded,plagiarism_warn_pct,plagiarism_checks,group_set,tutorial_stream,scorm_enabled,scorm_allow_review,scorm_bypass_test,scorm_time_delay_enabled,scorm_attempt_limit,assess_in_portfolio_only,task_prerequisites,discussion_prompts Pass Task 1.1 - Hello World,1.1P,"As a first step, create the classic 'Hello World' program. This will help ensure that you have all of the software installed correctly, and are ready to move on with creating other,,, programs.",1,0,FALSE,"[{""key"":""file1"",""name"":""HelloWorld.pas"",""type"":""code""},{""key"":""file1"",""name"":""Screenshot"",""type"":""image""}]",1,Tue,2,Tue,5,Mon,0,FALSE,90,,,import-tasks,FALSE,[],[] Pass Task 1.2 - Picture Drawing,1.2P,Create a program that calls procedures to draw a picture to a window (something other than a house which we use as the example).,2,0,FALSE,"[{""key"":""file0"",""name"":""PictureDrawing.pas"",""type"":""code""},{""key"":""file5"",""name"":""Screenshot"",""type"":""image""}]",1,Tue,2,Tue,5,Mon,0,FALSE,90,,,import-tasks,FALSE,[],[] Pass Task 1.3 - Creating a Procedure,1.3P,"Now that you have created a program that uses procedures, you can learn how to create your own procedures. Creating procedures will allow you to group your program's actions into procedures that perform meaningful tasks.",2,0,FALSE,"[{""key"":""file0"",""name"":""PictureDrawing.pas"",""type"":""code""},{""key"":""file3"",""name"":""Screenshot"",""type"":""image""},{""key"":""file2"",""name"":""Screenshot"",""type"":""image""}]",1,Tue,2,Tue,5,Mon,0,FALSE,90,,,import-tasks,FALSE,[],[] diff --git a/test_files/COS10001-TestImportTasks.csv b/test_files/COS10001-TestImportTasks.csv index 6e62fde57a..8924a5964b 100644 --- a/test_files/COS10001-TestImportTasks.csv +++ b/test_files/COS10001-TestImportTasks.csv @@ -1,4 +1,4 @@ -name,abbreviation,description,weighting,target_grade,restrict_status_updates,max_quality_pts,is_graded,upload_requirements,start_week,start_day,target_week,target_day,due_week,due_day,tutorial_stream -Imported Task 1,TEST_TASK1,Imported!,4,0,true,10,true,"[{""key"":""file0"",""name"":""Imported Code"",""type"":""code""}]",9,Mon,9,Mon,9,Wed,prac-1 -Imported Task 2,TEST_TASK2,Imported!,4,0,true,10,true,"[{""key"":""file0"",""name"":""Imported Code"",""type"":""code""}]",9,Mon,9,Mon,9,Wed,prac-1 -Imported Task 3,TEST_TASK3,Imported!,4,0,true,10,true,"[{""key"":""file0"",""name"":""Imported Code"",""type"":""code""}]",9,Mon,9,Mon,9,Wed,prac-1 +name,abbreviation,description,estimated_hours,target_grade,restrict_status_updates,max_quality_pts,is_graded,upload_requirements,start_week,start_day,target_week,target_day,due_week,due_day,tutorial_stream +Imported Task 1,TEST_TASK1,Imported!,4,0,true,10,true,"[{""key"":""file0"",""name"":""Imported Code"",""type"":""code""}]",9,Mon,9,Mon,9,Wed,prac-1 +Imported Task 2,TEST_TASK2,Imported!,4,0,true,10,true,"[{""key"":""file0"",""name"":""Imported Code"",""type"":""code""}]",9,Mon,9,Mon,9,Wed,prac-1 +Imported Task 3,TEST_TASK3,Imported!,4,0,true,10,true,"[{""key"":""file0"",""name"":""Imported Code"",""type"":""code""}]",9,Mon,9,Mon,9,Wed,prac-1 diff --git a/test_files/csv_test_files/COS10001-Tasks-Prerequisites.csv b/test_files/csv_test_files/COS10001-Tasks-Prerequisites.csv index a399ef52e7..4163143f10 100644 --- a/test_files/csv_test_files/COS10001-Tasks-Prerequisites.csv +++ b/test_files/csv_test_files/COS10001-Tasks-Prerequisites.csv @@ -1,4 +1,4 @@ -name,abbreviation,description,weighting,target_grade,restrict_status_updates,max_quality_pts,is_graded,plagiarism_warn_pct,plagiarism_checks,group_set,upload_requirements,start_week,start_day,target_week,target_day,due_week,due_day,scorm_enabled,scorm_allow_review,scorm_bypass_test,scorm_time_delay_enabled,scorm_attempt_limit,tutorial_stream,assess_in_portfolio_only,task_prerequisites,discussion_prompts +name,abbreviation,description,estimated_hours,target_grade,restrict_status_updates,max_quality_pts,is_graded,plagiarism_warn_pct,plagiarism_checks,group_set,upload_requirements,start_week,start_day,target_week,target_day,due_week,due_day,scorm_enabled,scorm_allow_review,scorm_bypass_test,scorm_time_delay_enabled,scorm_attempt_limit,tutorial_stream,assess_in_portfolio_only,task_prerequisites,discussion_prompts Assignment 12,A12,rerum ut fugit saepe ipsa in quidem,2,0,FALSE,0,FALSE,50,[],,"[{""key"":""file0"",""name"":""Assumenda accusamus quas"",""type"":""image""}]",-1,Sat,1,Mon,13,Mon,,,,,,import-tasks,FALSE,[],[] Pass task 1,1.1P,rerum ut fugit saepe ipsa in quidem,2,0,FALSE,0,FALSE,50,[],,"[{""key"":""file0"",""name"":""Assumenda accusamus quas"",""type"":""image""}]",-1,Sat,1,Mon,12,Mon,,,,,,import-tasks,FALSE,[],[] Pass task 2,2.1P,rerum ut fugit saepe ipsa in quidem,2,0,FALSE,0,FALSE,50,[],,"[{""key"":""file0"",""name"":""Assumenda accusamus quas"",""type"":""image""}]",-1,Sat,1,Mon,12,Mon,,,,,,import-tasks,FALSE,[],[] diff --git a/test_files/csv_test_files/COS10001-Tasks.csv b/test_files/csv_test_files/COS10001-Tasks.csv index 0bdc01213d..b81401540b 100644 --- a/test_files/csv_test_files/COS10001-Tasks.csv +++ b/test_files/csv_test_files/COS10001-Tasks.csv @@ -1,4 +1,4 @@ -name,abbreviation,description,weighting,target_grade,restrict_status_updates,max_quality_pts,is_graded,plagiarism_warn_pct,plagiarism_checks,group_set,upload_requirements,start_week,start_day,target_week,target_day,due_week,due_day,scorm_enabled,scorm_allow_review,scorm_bypass_test,scorm_time_delay_enabled,scorm_attempt_limit,tutorial_stream,assess_in_portfolio_only,task_prerequisites,discussion_prompts +name,abbreviation,description,estimated_hours,target_grade,restrict_status_updates,max_quality_pts,is_graded,plagiarism_warn_pct,plagiarism_checks,group_set,upload_requirements,start_week,start_day,target_week,target_day,due_week,due_day,scorm_enabled,scorm_allow_review,scorm_bypass_test,scorm_time_delay_enabled,scorm_attempt_limit,tutorial_stream,assess_in_portfolio_only,task_prerequisites,discussion_prompts Assignment 12,A12,rerum ut fugit saepe ipsa in quidem,2,0,FALSE,0,FALSE,50,[],,"[{""key"":""file0"",""name"":""Assumenda accusamus quas"",""type"":""image""}]",-1,Sat,1,Mon,13,Mon,,,,,,import-tasks,FALSE,[],[] Pass task 1,1.1P,rerum ut fugit saepe ipsa in quidem,2,0,FALSE,0,FALSE,50,[],,"[{""key"":""file0"",""name"":""Assumenda accusamus quas"",""type"":""image""}]",-1,Sat,1,Mon,12,Mon,,,,,,import-tasks,FALSE,[],[] Pass task 2,2.1P,rerum ut fugit saepe ipsa in quidem,2,0,FALSE,0,FALSE,50,[],,"[{""key"":""file0"",""name"":""Assumenda accusamus quas"",""type"":""image""}]",-1,Sat,1,Mon,12,Mon,,,,,,import-tasks,FALSE,[],[] diff --git a/test_files/csv_test_files/COS10001-Tasks.xlsx b/test_files/csv_test_files/COS10001-Tasks.xlsx index dfe25c7d0a..f7bf81f3aa 100644 Binary files a/test_files/csv_test_files/COS10001-Tasks.xlsx and b/test_files/csv_test_files/COS10001-Tasks.xlsx differ diff --git a/test_files/unit_csv_imports/import_group_tasks.csv b/test_files/unit_csv_imports/import_group_tasks.csv index 2b576cfebd..30ba5e49e8 100644 --- a/test_files/unit_csv_imports/import_group_tasks.csv +++ b/test_files/unit_csv_imports/import_group_tasks.csv @@ -1,3 +1,3 @@ -name,abbreviation,description,weighting,target_grade,restrict_status_updates,max_quality_pts,is_graded,plagiarism_warn_pct,plagiarism_checks,group_set,upload_requirements,start_week,start_day,target_week,target_day,due_week,due_day,tutorial_stream,scorm_enabled,scorm_allow_review,scorm_bypass_test,scorm_time_delay_enabled,scorm_attempt_limit,assess_in_portfolio_only,task_prerequisites,discussion_prompts +name,abbreviation,description,estimated_hours,target_grade,restrict_status_updates,max_quality_pts,is_graded,plagiarism_warn_pct,plagiarism_checks,group_set,upload_requirements,start_week,start_day,target_week,target_day,due_week,due_day,tutorial_stream,scorm_enabled,scorm_allow_review,scorm_bypass_test,scorm_time_delay_enabled,scorm_attempt_limit,assess_in_portfolio_only,task_prerequisites,discussion_prompts Group Import 1,1GI,Test Description - Import,16,0,FALSE,0,FALSE,80,[],Group Work,[],0,Mon,1,Sun,2,Wed,group-tasks-test,,,,FALSE,[],[] Missing Group,2GI,Test Description - Import FAIL,16,0,FALSE,0,FALSE,80,[],Group Work1,[],0,Mon,1,Sun,2,Wed,group-tasks-test,,,,FALSE,[],[] diff --git a/texlive.Dockerfile b/texlive.Dockerfile index c68816ce24..1ca6c9acff 100644 --- a/texlive.Dockerfile +++ b/texlive.Dockerfile @@ -53,7 +53,6 @@ RUN tlmgr install \ paralist \ pdfcol \ pdflscape \ - pdfmanagement-testphase \ pdfpages \ tagpdf \ tcolorbox \