From c683d455ee2fddbd98417a03ac6fb7bf4b86c285 Mon Sep 17 00:00:00 2001 From: Chris Preisinger Date: Fri, 23 Aug 2024 16:02:31 -0400 Subject: [PATCH] 125 Placeholder challenge manager eval files --- app/controllers/evaluation_forms_controller.rb | 5 +++++ app/controllers/manage_submissions_controller.rb | 5 +++++ app/helpers/evaluation_forms_helper.rb | 4 ++++ app/helpers/manage_submissions_helper.rb | 4 ++++ app/views/evaluation_forms/index.html.erb | 7 +++++++ app/views/manage_submissions/index.html.erb | 7 +++++++ config/routes.rb | 3 +++ spec/helpers/evaluation_forms_helper_spec.rb | 15 +++++++++++++++ spec/helpers/manage_submissions_helper_spec.rb | 15 +++++++++++++++ spec/requests/evaluation_forms_spec.rb | 11 +++++++++++ spec/requests/manage_submissions_spec.rb | 11 +++++++++++ .../views/evaluation_forms/index.html.erb_spec.rb | 5 +++++ .../manage_submissions/index.html.erb_spec.rb | 5 +++++ 13 files changed, 97 insertions(+) create mode 100644 app/controllers/evaluation_forms_controller.rb create mode 100644 app/controllers/manage_submissions_controller.rb create mode 100644 app/helpers/evaluation_forms_helper.rb create mode 100644 app/helpers/manage_submissions_helper.rb create mode 100644 app/views/evaluation_forms/index.html.erb create mode 100644 app/views/manage_submissions/index.html.erb create mode 100644 spec/helpers/evaluation_forms_helper_spec.rb create mode 100644 spec/helpers/manage_submissions_helper_spec.rb create mode 100644 spec/requests/evaluation_forms_spec.rb create mode 100644 spec/requests/manage_submissions_spec.rb create mode 100644 spec/views/evaluation_forms/index.html.erb_spec.rb create mode 100644 spec/views/manage_submissions/index.html.erb_spec.rb diff --git a/app/controllers/evaluation_forms_controller.rb b/app/controllers/evaluation_forms_controller.rb new file mode 100644 index 00000000..34119c8b --- /dev/null +++ b/app/controllers/evaluation_forms_controller.rb @@ -0,0 +1,5 @@ +# frozen_string_literal: true + +class EvaluationFormsController < ApplicationController + def index; end +end diff --git a/app/controllers/manage_submissions_controller.rb b/app/controllers/manage_submissions_controller.rb new file mode 100644 index 00000000..0505d138 --- /dev/null +++ b/app/controllers/manage_submissions_controller.rb @@ -0,0 +1,5 @@ +# frozen_string_literal: true + +class ManageSubmissionsController < ApplicationController + def index; end +end diff --git a/app/helpers/evaluation_forms_helper.rb b/app/helpers/evaluation_forms_helper.rb new file mode 100644 index 00000000..104f5ae5 --- /dev/null +++ b/app/helpers/evaluation_forms_helper.rb @@ -0,0 +1,4 @@ +# frozen_string_literal: true + +module EvaluationFormsHelper +end diff --git a/app/helpers/manage_submissions_helper.rb b/app/helpers/manage_submissions_helper.rb new file mode 100644 index 00000000..fcdfe6fb --- /dev/null +++ b/app/helpers/manage_submissions_helper.rb @@ -0,0 +1,4 @@ +# frozen_string_literal: true + +module ManageSubmissionsHelper +end diff --git a/app/views/evaluation_forms/index.html.erb b/app/views/evaluation_forms/index.html.erb new file mode 100644 index 00000000..c93238e6 --- /dev/null +++ b/app/views/evaluation_forms/index.html.erb @@ -0,0 +1,7 @@ +
+
+

Evaluation Forms

+ +

Placeholder text for Evaluation Forms.

+
+
diff --git a/app/views/manage_submissions/index.html.erb b/app/views/manage_submissions/index.html.erb new file mode 100644 index 00000000..7eb48703 --- /dev/null +++ b/app/views/manage_submissions/index.html.erb @@ -0,0 +1,7 @@ +
+
+

Manage Submissions

+ +

Placeholder text for Manage Submissions.

+
+
\ No newline at end of file diff --git a/config/routes.rb b/config/routes.rb index 7a1763af..bf9cb130 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -8,6 +8,9 @@ get '/', to: "dashboard#index" get '/dashboard', to: "dashboard#index" + resources :evaluation_forms, only: [:index] + resources :manage_submissions, only: [:index] + # Reveal health status on /up that returns 200 if the app boots with no exceptions, otherwise 500. # Can be used by load balancers and uptime monitors to verify that the app is live. get "up" => "rails/health#show", as: :rails_health_check diff --git a/spec/helpers/evaluation_forms_helper_spec.rb b/spec/helpers/evaluation_forms_helper_spec.rb new file mode 100644 index 00000000..5b93a9b5 --- /dev/null +++ b/spec/helpers/evaluation_forms_helper_spec.rb @@ -0,0 +1,15 @@ +require 'rails_helper' + +# Specs in this file have access to a helper object that includes +# the EvaluationFormsHelper. For example: +# +# describe EvaluationFormsHelper do +# describe "string concat" do +# it "concats two strings with spaces" do +# expect(helper.concat_strings("this","that")).to eq("this that") +# end +# end +# end +RSpec.describe EvaluationFormsHelper, type: :helper do + pending "add some examples to (or delete) #{__FILE__}" +end diff --git a/spec/helpers/manage_submissions_helper_spec.rb b/spec/helpers/manage_submissions_helper_spec.rb new file mode 100644 index 00000000..84840f50 --- /dev/null +++ b/spec/helpers/manage_submissions_helper_spec.rb @@ -0,0 +1,15 @@ +require 'rails_helper' + +# Specs in this file have access to a helper object that includes +# the ManageSubmissionsHelper. For example: +# +# describe ManageSubmissionsHelper do +# describe "string concat" do +# it "concats two strings with spaces" do +# expect(helper.concat_strings("this","that")).to eq("this that") +# end +# end +# end +RSpec.describe ManageSubmissionsHelper, type: :helper do + pending "add some examples to (or delete) #{__FILE__}" +end diff --git a/spec/requests/evaluation_forms_spec.rb b/spec/requests/evaluation_forms_spec.rb new file mode 100644 index 00000000..9171ccf3 --- /dev/null +++ b/spec/requests/evaluation_forms_spec.rb @@ -0,0 +1,11 @@ +require 'rails_helper' + +RSpec.describe "EvaluationForms", type: :request do + describe "GET /evaluation_forms" do + it "renders the index view with the correct header" do + get evaluation_forms_path + expect(response).to have_http_status(:success) + expect(response.body).to include("Evaluation Forms") + end + end +end diff --git a/spec/requests/manage_submissions_spec.rb b/spec/requests/manage_submissions_spec.rb new file mode 100644 index 00000000..3b1bb79b --- /dev/null +++ b/spec/requests/manage_submissions_spec.rb @@ -0,0 +1,11 @@ +require 'rails_helper' + +RSpec.describe "ManageSubmissions", type: :request do + describe "GET /manage_submissions" do + it "renders the index view with the correct header" do + get manage_submissions_path + expect(response).to have_http_status(:success) + expect(response.body).to include("Manage Submissions") + end + end +end diff --git a/spec/views/evaluation_forms/index.html.erb_spec.rb b/spec/views/evaluation_forms/index.html.erb_spec.rb new file mode 100644 index 00000000..0019feeb --- /dev/null +++ b/spec/views/evaluation_forms/index.html.erb_spec.rb @@ -0,0 +1,5 @@ +require 'rails_helper' + +RSpec.describe "evaluation_forms/index.html.erb", type: :view do + pending "add some examples to (or delete) #{__FILE__}" +end diff --git a/spec/views/manage_submissions/index.html.erb_spec.rb b/spec/views/manage_submissions/index.html.erb_spec.rb new file mode 100644 index 00000000..6fd7043e --- /dev/null +++ b/spec/views/manage_submissions/index.html.erb_spec.rb @@ -0,0 +1,5 @@ +require 'rails_helper' + +RSpec.describe "manage_submissions/index.html.erb", type: :view do + pending "add some examples to (or delete) #{__FILE__}" +end