CSC/ECE 517 Spring 2023 - E2303 Refactor teams controller.rb: Difference between revisions

From Expertiza_Wiki
Jump to navigation Jump to search
No edit summary
Line 10: Line 10:


# Added more comments and briefly explained the functionality of all methods  
# Added more comments and briefly explained the functionality of all methods  
# Found areas in the code where the DRY principle can be applied
# Refactored the function <code>bequeath_all</code> to improve readability by including function <code>copy_teams</code>
# Refactored function <code>copy_teams</code>


==Files Changed==
==Files Changed==


* app/controllers/teams_controller.rb
* app/controllers/teams_controller.rb
* app/models/teams.rb
* config/locales/hi_IN.yml
* config/locales/hi_IN.yml
* spec/controllers/teams_controller_spec.rb
* spec/controllers/teams_controller_spec.rb

Revision as of 01:59, 23 March 2023

Expertiza

Expertiza is a Ruby on Rails based open source project. Instructors have the ability to add new projects, assignments, etc., as well as edit existing ones. Later on, they can view student submissions and grade them. Students can also use Expertiza to organize into teams to work on different projects and assignments and submit their work. They can also review other students' submissions.

Introduction

In this project we refactored teams_controller.rb and some tests associated with it. Some duplicate code was removed. We added some comments for readability. And, we fixed tests to be more consistent with the program and execution.

Issues Fixed

  1. Added more comments and briefly explained the functionality of all methods
  2. Found areas in the code where the DRY principle can be applied
  3. Refactored the function bequeath_all to improve readability by including function copy_teams
  4. Refactored function copy_teams

Files Changed

  • app/controllers/teams_controller.rb
  • app/models/teams.rb
  • config/locales/hi_IN.yml
  • spec/controllers/teams_controller_spec.rb

Changes

Fix #1

This is Fix 1

Fix #2

This is Fix 2

Fix #3

This is Fix 3

Test Plan

This is Test Plan

Test Coverage

This is Test Coverage

Contributors

This project was done as part of Dr. Edward Gehringer's "CSC/ECE 517: Object-Oriented Design and Development" class, Spring 2023. The contributors were: Sasank Marabattula, Srilekha Gudipati and Varun Deepak Gudhe. Our project mentor was Divyang Doshi.