<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.expertiza.ncsu.edu/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Msardar</id>
	<title>Expertiza_Wiki - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.expertiza.ncsu.edu/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Msardar"/>
	<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=Special:Contributions/Msardar"/>
	<updated>2026-06-10T14:12:20Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.41.0</generator>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=106143</id>
		<title>CSC/ECE 517 Fall 2016/E1693. Drag-and-drop interface for creating rubrics</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=106143"/>
		<updated>2016-12-02T23:28:07Z</updated>

		<summary type="html">&lt;p&gt;Msardar: /* Implementation */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''Introduction to Expertiza''' ==&lt;br /&gt;
Expertiza is an online system that is used by students to view/submit assignments and review others' work. Expertiza also provides tools to visualize the scores and gauge the improvements made during the course semester. It also facilitates and monitors team projects. It is targeted at educational and non-profit organizations. &lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source project with the source code available as a public repository on GitHub. It is developed using Ruby on Rails and is increasingly becoming robust thanks to the innumerable bugs being fixed by the community. The project has a micro-blog on SourceForge where the developer community report bugs and document updates.&lt;br /&gt;
&lt;br /&gt;
=='''Problem Statement'''==&lt;br /&gt;
&lt;br /&gt;
The existing interface for defining rubric is not very user friendly. The instructors or TAs are required to define the type of the field, the dimension of the fields (length, height), and possibly the content of the widget e.g., available options for a combo box. Unfortunately, after they are done with the design phase, to see the final result of the rubric that is going to be presented to the students, they have to impersonate students, create a fake submissions, move the due dates etc. The existing rubrics creation page is shown in the Figure below.&lt;br /&gt;
&lt;br /&gt;
[[File:OldRubricPage.PNG|frame|upright|center|Old Rubric Creation Page]]&lt;br /&gt;
&lt;br /&gt;
As mentioned before, the above shown page is not very intuitive. Also the instructor has no idea how the page would appear to a student unless he logs in as a student, create submissions, etc. which is very time consuming. Hence a better design would be to create a rubrics page that would appear the same to the instructors and the students.&lt;br /&gt;
&lt;br /&gt;
We need to implement a WYSIWYG (What You See Is What You Get) UI for the rubric page to create rubrics which supports the following expertiza's question types:&lt;br /&gt;
&lt;br /&gt;
* Criterion&lt;br /&gt;
* Checkbox&lt;br /&gt;
* TextField&lt;br /&gt;
* Dropdown&lt;br /&gt;
* TextArea&lt;br /&gt;
* UploadFile&lt;br /&gt;
*  SectionHeader&lt;br /&gt;
* TableHeader&lt;br /&gt;
* ColumnHeader&lt;br /&gt;
* Scale&lt;br /&gt;
&lt;br /&gt;
== '''Design''' ==&lt;br /&gt;
To create the drag-and-drop interface, we can use the [https://formbuilder.online jQuery formBuilder plugin]. The 'jquery-rails' gem is already present in the Gemfile, so we only need to initialize the formBuilder plugin.&lt;br /&gt;
&lt;br /&gt;
The advantages of using this plugin are:&lt;br /&gt;
&lt;br /&gt;
* 100% client-side plugin that gives users the power to create forms using an intuitive drag and drop interface.&lt;br /&gt;
* Customization - enable only the fields you need, use your own notifications append or prepend content and more.&lt;br /&gt;
* Bootstrap ready but not dependent&lt;br /&gt;
&lt;br /&gt;
A mockup for an example form is given below:&lt;br /&gt;
&lt;br /&gt;
[[File:JQuery.png|frame|upright|center|Sample Form using JQuery formBuilder]]&lt;br /&gt;
&lt;br /&gt;
The above screenshot consists of two sections: main area to the left and the control section to the right. The control section consists of the various form fields which can be dragged and dropped to the main area. In the main area, the parameters to the fields can be configured including field length, options, values, etc. Hence the drag and drop interface will provide a very intuitive way for the instructor/TA to create rubrics and also view how the page would appear to a student. Moreover it provides the option to edit the field information when we create the individual fields. For example, in case of dropdown we can specify the options of the dropdown. A sample screenshot of text area creation is shown below.&lt;br /&gt;
&lt;br /&gt;
[[File:text_area.PNG|frame|upright|center|Text Area Creation]]&lt;br /&gt;
&lt;br /&gt;
In the above screenshot, we can see that we are creating a text area. There is an edit option at the top right corner of the field, clicking on which we get a form through which the options can be given. In the above case of creating a text area, we can specify the label, value, number of rows, the maximum length of the characters, placeholder, help text, etc. We can also specify if the field is mandatory by checking the required checkbox given at the top of the form. In a similar way configuration options are available to all the form fields that can be created.&lt;br /&gt;
&lt;br /&gt;
== '''Files to be modified''' ==&lt;br /&gt;
This project only involves modifying the UI for instructors to create new rubrics. The rubric configurations stored in the database and the views from the student side will remain the same. Hence, no modifications need to be made to the questionnaire model or controller.&lt;br /&gt;
&lt;br /&gt;
All types of rubrics (Review, Metareview, Author Feedback, Teammate review, Survey, Course Evaluation etc.) are created and modified using the same views. These views exist in views/questionnaires folder. Hence the files to be modified to incorporate the new UI design will be:&lt;br /&gt;
&lt;br /&gt;
# view/questionnaires/new.html.erb&lt;br /&gt;
# view/questionnaires/edit.html.erb&lt;br /&gt;
# view/questionnaires/view.html.erb&lt;br /&gt;
&lt;br /&gt;
The modifications made to the above files will be significant since the new rubric creation interface will be entirely different form the existing one. A lot of the code will have to be written from scratch.&lt;br /&gt;
== '''Implementation''' ==&lt;br /&gt;
To implement the drag-and-drop interface, we need to incorporate the source code from [https://github.com/kevinchappell/formBuilder/ GitHub] into our existing Expertiza project by adding them in &amp;quot;/vendor/assets/&amp;quot; folder.&lt;br /&gt;
&lt;br /&gt;
To intialize the jQuery formBuilder plugin, a file needs to be added under &amp;quot;/app/assets/javascripts/&amp;quot; folder named &amp;quot;form-init.js&amp;quot;. Within this file we need to specify the options to match our required form for rubric creation. The code for this is as follows :&lt;br /&gt;
&lt;br /&gt;
  fbOptions = {&lt;br /&gt;
  	    dataType: 'json',&lt;br /&gt;
  	    sortableControls: false,&lt;br /&gt;
  	    editOnAdd: false,&lt;br /&gt;
  	    stickyControls: true, &lt;br /&gt;
  	    sortableControls: false, &lt;br /&gt;
  	    disableFields: ['autocomplete', 'button','paragraph', 'number', 'checkbox-group', 'date', 'file', 'hidden', 'header'],  			     		    &lt;br /&gt;
  	    editOnAdd: false, &lt;br /&gt;
  	    showActionButtons: true, &lt;br /&gt;
  		defaultFields: defaultFields, // edit will load the fields from db&lt;br /&gt;
  		fieldRemoveWarn: true,&lt;br /&gt;
  	    typeUserEvents: {&lt;br /&gt;
  			'checkbox': onAddHandler,&lt;br /&gt;
  			'header': onAddHandler,&lt;br /&gt;
  			'radio-group': onAddHandler,&lt;br /&gt;
  			'select': onAddHandler,&lt;br /&gt;
  			'text': onAddHandler,&lt;br /&gt;
  			'textarea': onAddHandler&lt;br /&gt;
  	    }&lt;br /&gt;
  	};&lt;br /&gt;
    var formBuilder = $(buildWrap).formBuilder(fbOptions).data('formBuilder')&lt;br /&gt;
&lt;br /&gt;
We also need to make sure that data entered into the new interface is stored into the existing database in the same format as the current one. &lt;br /&gt;
&lt;br /&gt;
After implementation of the above code, the final UI for rubric creations looks like : &lt;br /&gt;
[[File:New1.png|frame|upright|center|Sample Form using JQuery formBuilder]]&lt;br /&gt;
&lt;br /&gt;
Instructors can select field type on the right and drop it into the container. Then select different options for each field type such as labels, values, length etc.&lt;br /&gt;
&lt;br /&gt;
== '''Testing Plan''' ==&lt;br /&gt;
&lt;br /&gt;
[[File:inst-flow.png | frame | upright | center | Instructor Flow Diagram]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
# Login as instructor (username: instructor6, password:password).&lt;br /&gt;
# Click on 'Questionnaires' tab present in the Manage section.&lt;br /&gt;
# Click on 'New public item' to go to the 'Create ReviewQuestionnaire&amp;quot; page.&lt;br /&gt;
# Click on 'Create' icon which will forward you to &amp;quot;form Builder&amp;quot; page.&lt;br /&gt;
# Now you can create a sample rubrics by dragging and dropping the form fields and configuring the field parameters.&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=106136</id>
		<title>CSC/ECE 517 Fall 2016/E1693. Drag-and-drop interface for creating rubrics</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=106136"/>
		<updated>2016-12-02T23:23:01Z</updated>

		<summary type="html">&lt;p&gt;Msardar: /* Implementation */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''Introduction to Expertiza''' ==&lt;br /&gt;
Expertiza is an online system that is used by students to view/submit assignments and review others' work. Expertiza also provides tools to visualize the scores and gauge the improvements made during the course semester. It also facilitates and monitors team projects. It is targeted at educational and non-profit organizations. &lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source project with the source code available as a public repository on GitHub. It is developed using Ruby on Rails and is increasingly becoming robust thanks to the innumerable bugs being fixed by the community. The project has a micro-blog on SourceForge where the developer community report bugs and document updates.&lt;br /&gt;
&lt;br /&gt;
=='''Problem Statement'''==&lt;br /&gt;
&lt;br /&gt;
The existing interface for defining rubric is not very user friendly. The instructors or TAs are required to define the type of the field, the dimension of the fields (length, height), and possibly the content of the widget e.g., available options for a combo box. Unfortunately, after they are done with the design phase, to see the final result of the rubric that is going to be presented to the students, they have to impersonate students, create a fake submissions, move the due dates etc. The existing rubrics creation page is shown in the Figure below.&lt;br /&gt;
&lt;br /&gt;
[[File:OldRubricPage.PNG|frame|upright|center|Old Rubric Creation Page]]&lt;br /&gt;
&lt;br /&gt;
As mentioned before, the above shown page is not very intuitive. Also the instructor has no idea how the page would appear to a student unless he logs in as a student, create submissions, etc. which is very time consuming. Hence a better design would be to create a rubrics page that would appear the same to the instructors and the students.&lt;br /&gt;
&lt;br /&gt;
We need to implement a WYSIWYG (What You See Is What You Get) UI for the rubric page to create rubrics which supports the following expertiza's question types:&lt;br /&gt;
&lt;br /&gt;
* Criterion&lt;br /&gt;
* Checkbox&lt;br /&gt;
* TextField&lt;br /&gt;
* Dropdown&lt;br /&gt;
* TextArea&lt;br /&gt;
* UploadFile&lt;br /&gt;
*  SectionHeader&lt;br /&gt;
* TableHeader&lt;br /&gt;
* ColumnHeader&lt;br /&gt;
* Scale&lt;br /&gt;
&lt;br /&gt;
== '''Design''' ==&lt;br /&gt;
To create the drag-and-drop interface, we can use the [https://formbuilder.online jQuery formBuilder plugin]. The 'jquery-rails' gem is already present in the Gemfile, so we only need to initialize the formBuilder plugin.&lt;br /&gt;
&lt;br /&gt;
The advantages of using this plugin are:&lt;br /&gt;
&lt;br /&gt;
* 100% client-side plugin that gives users the power to create forms using an intuitive drag and drop interface.&lt;br /&gt;
* Customization - enable only the fields you need, use your own notifications append or prepend content and more.&lt;br /&gt;
* Bootstrap ready but not dependent&lt;br /&gt;
&lt;br /&gt;
A mockup for an example form is given below:&lt;br /&gt;
&lt;br /&gt;
[[File:JQuery.png|frame|upright|center|Sample Form using JQuery formBuilder]]&lt;br /&gt;
&lt;br /&gt;
The above screenshot consists of two sections: main area to the left and the control section to the right. The control section consists of the various form fields which can be dragged and dropped to the main area. In the main area, the parameters to the fields can be configured including field length, options, values, etc. Hence the drag and drop interface will provide a very intuitive way for the instructor/TA to create rubrics and also view how the page would appear to a student. Moreover it provides the option to edit the field information when we create the individual fields. For example, in case of dropdown we can specify the options of the dropdown. A sample screenshot of text area creation is shown below.&lt;br /&gt;
&lt;br /&gt;
[[File:text_area.PNG|frame|upright|center|Text Area Creation]]&lt;br /&gt;
&lt;br /&gt;
In the above screenshot, we can see that we are creating a text area. There is an edit option at the top right corner of the field, clicking on which we get a form through which the options can be given. In the above case of creating a text area, we can specify the label, value, number of rows, the maximum length of the characters, placeholder, help text, etc. We can also specify if the field is mandatory by checking the required checkbox given at the top of the form. In a similar way configuration options are available to all the form fields that can be created.&lt;br /&gt;
&lt;br /&gt;
== '''Files to be modified''' ==&lt;br /&gt;
This project only involves modifying the UI for instructors to create new rubrics. The rubric configurations stored in the database and the views from the student side will remain the same. Hence, no modifications need to be made to the questionnaire model or controller.&lt;br /&gt;
&lt;br /&gt;
All types of rubrics (Review, Metareview, Author Feedback, Teammate review, Survey, Course Evaluation etc.) are created and modified using the same views. These views exist in views/questionnaires folder. Hence the files to be modified to incorporate the new UI design will be:&lt;br /&gt;
&lt;br /&gt;
# view/questionnaires/new.html.erb&lt;br /&gt;
# view/questionnaires/edit.html.erb&lt;br /&gt;
# view/questionnaires/view.html.erb&lt;br /&gt;
&lt;br /&gt;
The modifications made to the above files will be significant since the new rubric creation interface will be entirely different form the existing one. A lot of the code will have to be written from scratch.&lt;br /&gt;
== '''Implementation''' ==&lt;br /&gt;
To implement the drag-and-drop interface, we need to incorporate the source code from [https://github.com/kevinchappell/formBuilder/ GitHub] into our existing Expertiza project by adding them in &amp;quot;/vendor/assets/&amp;quot; folder.&lt;br /&gt;
&lt;br /&gt;
To intialize the jQuery formBuilder plugin, a file needs to be added under &amp;quot;/app/assets/javascripts/&amp;quot; folder named &amp;quot;form-init.js&amp;quot;. Within this file we need to specify the options to match our required form for rubric creation. The code for this is as follows :&lt;br /&gt;
&lt;br /&gt;
  fbOptions = {&lt;br /&gt;
  	    dataType: 'json',&lt;br /&gt;
  	    sortableControls: false,&lt;br /&gt;
  	    editOnAdd: false,&lt;br /&gt;
  	    stickyControls: true, &lt;br /&gt;
  	    sortableControls: false, &lt;br /&gt;
  	    disableFields: ['autocomplete', 'button','paragraph', 'number', 'checkbox-group', 'date', 'file', 'hidden', 'header'],  			     		    &lt;br /&gt;
  	    editOnAdd: false, &lt;br /&gt;
  	    showActionButtons: true, &lt;br /&gt;
  		defaultFields: defaultFields, // edit will load the fields from db&lt;br /&gt;
  		fieldRemoveWarn: true,&lt;br /&gt;
  	    typeUserEvents: {&lt;br /&gt;
  			'checkbox': onAddHandler,&lt;br /&gt;
  			'header': onAddHandler,&lt;br /&gt;
  			'radio-group': onAddHandler,&lt;br /&gt;
  			'select': onAddHandler,&lt;br /&gt;
  			'text': onAddHandler,&lt;br /&gt;
  			'textarea': onAddHandler&lt;br /&gt;
  	    }&lt;br /&gt;
  	};&lt;br /&gt;
    var formBuilder = $(buildWrap).formBuilder(fbOptions).data('formBuilder')&lt;br /&gt;
&lt;br /&gt;
We also need to make sure that data entered into the new interface is stored into the existing database in the same format as the current one. &lt;br /&gt;
&lt;br /&gt;
After implementation of the above code, the final UI for rubric creations looks like : &lt;br /&gt;
[[File:New1.png|frame|upright|center|Sample Form using JQuery formBuilder]]&lt;br /&gt;
&lt;br /&gt;
== '''Testing Plan''' ==&lt;br /&gt;
&lt;br /&gt;
[[File:inst-flow.png | frame | upright | center | Instructor Flow Diagram]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
# Login as instructor (username: instructor6, password:password).&lt;br /&gt;
# Click on 'Questionnaires' tab present in the Manage section.&lt;br /&gt;
# Click on 'New public item' to go to the 'Create ReviewQuestionnaire&amp;quot; page.&lt;br /&gt;
# Click on 'Create' icon which will forward you to &amp;quot;form Builder&amp;quot; page.&lt;br /&gt;
# Now you can create a sample rubrics by dragging and dropping the form fields and configuring the field parameters.&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=106123</id>
		<title>CSC/ECE 517 Fall 2016/E1693. Drag-and-drop interface for creating rubrics</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=106123"/>
		<updated>2016-12-02T23:09:06Z</updated>

		<summary type="html">&lt;p&gt;Msardar: /* Implementation */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''Introduction to Expertiza''' ==&lt;br /&gt;
Expertiza is an online system that is used by students to view/submit assignments and review others' work. Expertiza also provides tools to visualize the scores and gauge the improvements made during the course semester. It also facilitates and monitors team projects. It is targeted at educational and non-profit organizations. &lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source project with the source code available as a public repository on GitHub. It is developed using Ruby on Rails and is increasingly becoming robust thanks to the innumerable bugs being fixed by the community. The project has a micro-blog on SourceForge where the developer community report bugs and document updates.&lt;br /&gt;
&lt;br /&gt;
=='''Problem Statement'''==&lt;br /&gt;
&lt;br /&gt;
The existing interface for defining rubric is not very user friendly. The instructors or TAs are required to define the type of the field, the dimension of the fields (length, height), and possibly the content of the widget e.g., available options for a combo box. Unfortunately, after they are done with the design phase, to see the final result of the rubric that is going to be presented to the students, they have to impersonate students, create a fake submissions, move the due dates etc. The existing rubrics creation page is shown in the Figure below.&lt;br /&gt;
&lt;br /&gt;
[[File:OldRubricPage.PNG|frame|upright|center|Old Rubric Creation Page]]&lt;br /&gt;
&lt;br /&gt;
As mentioned before, the above shown page is not very intuitive. Also the instructor has no idea how the page would appear to a student unless he logs in as a student, create submissions, etc. which is very time consuming. Hence a better design would be to create a rubrics page that would appear the same to the instructors and the students.&lt;br /&gt;
&lt;br /&gt;
We need to implement a WYSIWYG (What You See Is What You Get) UI for the rubric page to create rubrics which supports the following expertiza's question types:&lt;br /&gt;
&lt;br /&gt;
* Criterion&lt;br /&gt;
* Checkbox&lt;br /&gt;
* TextField&lt;br /&gt;
* Dropdown&lt;br /&gt;
* TextArea&lt;br /&gt;
* UploadFile&lt;br /&gt;
*  SectionHeader&lt;br /&gt;
* TableHeader&lt;br /&gt;
* ColumnHeader&lt;br /&gt;
* Scale&lt;br /&gt;
&lt;br /&gt;
== '''Design''' ==&lt;br /&gt;
To create the drag-and-drop interface, we can use the [https://formbuilder.online jQuery formBuilder plugin]. The 'jquery-rails' gem is already present in the Gemfile, so we only need to initialize the formBuilder plugin.&lt;br /&gt;
&lt;br /&gt;
The advantages of using this plugin are:&lt;br /&gt;
&lt;br /&gt;
* 100% client-side plugin that gives users the power to create forms using an intuitive drag and drop interface.&lt;br /&gt;
* Customization - enable only the fields you need, use your own notifications append or prepend content and more.&lt;br /&gt;
* Bootstrap ready but not dependent&lt;br /&gt;
&lt;br /&gt;
A mockup for an example form is given below:&lt;br /&gt;
&lt;br /&gt;
[[File:JQuery.png|frame|upright|center|Sample Form using JQuery formBuilder]]&lt;br /&gt;
&lt;br /&gt;
The above screenshot consists of two sections: main area to the left and the control section to the right. The control section consists of the various form fields which can be dragged and dropped to the main area. In the main area, the parameters to the fields can be configured including field length, options, values, etc. Hence the drag and drop interface will provide a very intuitive way for the instructor/TA to create rubrics and also view how the page would appear to a student. Moreover it provides the option to edit the field information when we create the individual fields. For example, in case of dropdown we can specify the options of the dropdown. A sample screenshot of text area creation is shown below.&lt;br /&gt;
&lt;br /&gt;
[[File:text_area.PNG|frame|upright|center|Text Area Creation]]&lt;br /&gt;
&lt;br /&gt;
In the above screenshot, we can see that we are creating a text area. There is an edit option at the top right corner of the field, clicking on which we get a form through which the options can be given. In the above case of creating a text area, we can specify the label, value, number of rows, the maximum length of the characters, placeholder, help text, etc. We can also specify if the field is mandatory by checking the required checkbox given at the top of the form. In a similar way configuration options are available to all the form fields that can be created.&lt;br /&gt;
&lt;br /&gt;
== '''Files to be modified''' ==&lt;br /&gt;
This project only involves modifying the UI for instructors to create new rubrics. The rubric configurations stored in the database and the views from the student side will remain the same. Hence, no modifications need to be made to the questionnaire model or controller.&lt;br /&gt;
&lt;br /&gt;
All types of rubrics (Review, Metareview, Author Feedback, Teammate review, Survey, Course Evaluation etc.) are created and modified using the same views. These views exist in views/questionnaires folder. Hence the files to be modified to incorporate the new UI design will be:&lt;br /&gt;
&lt;br /&gt;
# view/questionnaires/new.html.erb&lt;br /&gt;
# view/questionnaires/edit.html.erb&lt;br /&gt;
# view/questionnaires/view.html.erb&lt;br /&gt;
&lt;br /&gt;
The modifications made to the above files will be significant since the new rubric creation interface will be entirely different form the existing one. A lot of the code will have to be written from scratch.&lt;br /&gt;
== '''Implementation''' ==&lt;br /&gt;
To implement the drag-and-drop interface, we need to incorporate the source code from [https://github.com/kevinchappell/formBuilder/ GitHub] into our existing Expertiza project by adding them in &amp;quot;/vendor/assets/&amp;quot; folder.&lt;br /&gt;
&lt;br /&gt;
To intialize the jQuery formBuilder plugin, a file needs to be added under &amp;quot;/app/assets/javascripts/&amp;quot; folder named &amp;quot;form-init.js&amp;quot;. Within this file we need to specify the options to match our required form for rubric creation. The code for this is as follows :&lt;br /&gt;
&lt;br /&gt;
  fbOptions = {&lt;br /&gt;
  	    dataType: 'json',&lt;br /&gt;
  	    sortableControls: false,&lt;br /&gt;
  	    editOnAdd: false,&lt;br /&gt;
  	    stickyControls: true, &lt;br /&gt;
  	    sortableControls: false, &lt;br /&gt;
  	    disableFields: ['autocomplete', 'button','paragraph', 'number', 'checkbox-group', 'date', 'file', 'hidden', 'header'],  			     		    &lt;br /&gt;
  	    editOnAdd: false, &lt;br /&gt;
  	    showActionButtons: true, &lt;br /&gt;
  		defaultFields: defaultFields, // edit will load the fields from db&lt;br /&gt;
  		fieldRemoveWarn: true,&lt;br /&gt;
  	    typeUserEvents: {&lt;br /&gt;
  			'checkbox': onAddHandler,&lt;br /&gt;
  			'header': onAddHandler,&lt;br /&gt;
  			'radio-group': onAddHandler,&lt;br /&gt;
  			'select': onAddHandler,&lt;br /&gt;
  			'text': onAddHandler,&lt;br /&gt;
  			'textarea': onAddHandler&lt;br /&gt;
  	    }&lt;br /&gt;
  	};&lt;br /&gt;
    var formBuilder = $(buildWrap).formBuilder(fbOptions).data('formBuilder')&lt;br /&gt;
&lt;br /&gt;
The final UI for rubric creations looks like : &lt;br /&gt;
[[File:Form.png|frame|upright|center|Sample Form using JQuery formBuilder]]&lt;br /&gt;
&lt;br /&gt;
== '''Testing Plan''' ==&lt;br /&gt;
&lt;br /&gt;
[[File:inst-flow.png | frame | upright | center | Instructor Flow Diagram]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
# Login as instructor (username: instructor6, password:password).&lt;br /&gt;
# Click on 'Questionnaires' tab present in the Manage section.&lt;br /&gt;
# Click on 'New public item' to go to the 'Create ReviewQuestionnaire&amp;quot; page.&lt;br /&gt;
# Click on 'Create' icon which will forward you to &amp;quot;form Builder&amp;quot; page.&lt;br /&gt;
# Now you can create a sample rubrics by dragging and dropping the form fields and configuring the field parameters.&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=106121</id>
		<title>CSC/ECE 517 Fall 2016/E1693. Drag-and-drop interface for creating rubrics</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=106121"/>
		<updated>2016-12-02T23:08:02Z</updated>

		<summary type="html">&lt;p&gt;Msardar: /* Implementation */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''Introduction to Expertiza''' ==&lt;br /&gt;
Expertiza is an online system that is used by students to view/submit assignments and review others' work. Expertiza also provides tools to visualize the scores and gauge the improvements made during the course semester. It also facilitates and monitors team projects. It is targeted at educational and non-profit organizations. &lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source project with the source code available as a public repository on GitHub. It is developed using Ruby on Rails and is increasingly becoming robust thanks to the innumerable bugs being fixed by the community. The project has a micro-blog on SourceForge where the developer community report bugs and document updates.&lt;br /&gt;
&lt;br /&gt;
=='''Problem Statement'''==&lt;br /&gt;
&lt;br /&gt;
The existing interface for defining rubric is not very user friendly. The instructors or TAs are required to define the type of the field, the dimension of the fields (length, height), and possibly the content of the widget e.g., available options for a combo box. Unfortunately, after they are done with the design phase, to see the final result of the rubric that is going to be presented to the students, they have to impersonate students, create a fake submissions, move the due dates etc. The existing rubrics creation page is shown in the Figure below.&lt;br /&gt;
&lt;br /&gt;
[[File:OldRubricPage.PNG|frame|upright|center|Old Rubric Creation Page]]&lt;br /&gt;
&lt;br /&gt;
As mentioned before, the above shown page is not very intuitive. Also the instructor has no idea how the page would appear to a student unless he logs in as a student, create submissions, etc. which is very time consuming. Hence a better design would be to create a rubrics page that would appear the same to the instructors and the students.&lt;br /&gt;
&lt;br /&gt;
We need to implement a WYSIWYG (What You See Is What You Get) UI for the rubric page to create rubrics which supports the following expertiza's question types:&lt;br /&gt;
&lt;br /&gt;
* Criterion&lt;br /&gt;
* Checkbox&lt;br /&gt;
* TextField&lt;br /&gt;
* Dropdown&lt;br /&gt;
* TextArea&lt;br /&gt;
* UploadFile&lt;br /&gt;
*  SectionHeader&lt;br /&gt;
* TableHeader&lt;br /&gt;
* ColumnHeader&lt;br /&gt;
* Scale&lt;br /&gt;
&lt;br /&gt;
== '''Design''' ==&lt;br /&gt;
To create the drag-and-drop interface, we can use the [https://formbuilder.online jQuery formBuilder plugin]. The 'jquery-rails' gem is already present in the Gemfile, so we only need to initialize the formBuilder plugin.&lt;br /&gt;
&lt;br /&gt;
The advantages of using this plugin are:&lt;br /&gt;
&lt;br /&gt;
* 100% client-side plugin that gives users the power to create forms using an intuitive drag and drop interface.&lt;br /&gt;
* Customization - enable only the fields you need, use your own notifications append or prepend content and more.&lt;br /&gt;
* Bootstrap ready but not dependent&lt;br /&gt;
&lt;br /&gt;
A mockup for an example form is given below:&lt;br /&gt;
&lt;br /&gt;
[[File:JQuery.png|frame|upright|center|Sample Form using JQuery formBuilder]]&lt;br /&gt;
&lt;br /&gt;
The above screenshot consists of two sections: main area to the left and the control section to the right. The control section consists of the various form fields which can be dragged and dropped to the main area. In the main area, the parameters to the fields can be configured including field length, options, values, etc. Hence the drag and drop interface will provide a very intuitive way for the instructor/TA to create rubrics and also view how the page would appear to a student. Moreover it provides the option to edit the field information when we create the individual fields. For example, in case of dropdown we can specify the options of the dropdown. A sample screenshot of text area creation is shown below.&lt;br /&gt;
&lt;br /&gt;
[[File:text_area.PNG|frame|upright|center|Text Area Creation]]&lt;br /&gt;
&lt;br /&gt;
In the above screenshot, we can see that we are creating a text area. There is an edit option at the top right corner of the field, clicking on which we get a form through which the options can be given. In the above case of creating a text area, we can specify the label, value, number of rows, the maximum length of the characters, placeholder, help text, etc. We can also specify if the field is mandatory by checking the required checkbox given at the top of the form. In a similar way configuration options are available to all the form fields that can be created.&lt;br /&gt;
&lt;br /&gt;
== '''Files to be modified''' ==&lt;br /&gt;
This project only involves modifying the UI for instructors to create new rubrics. The rubric configurations stored in the database and the views from the student side will remain the same. Hence, no modifications need to be made to the questionnaire model or controller.&lt;br /&gt;
&lt;br /&gt;
All types of rubrics (Review, Metareview, Author Feedback, Teammate review, Survey, Course Evaluation etc.) are created and modified using the same views. These views exist in views/questionnaires folder. Hence the files to be modified to incorporate the new UI design will be:&lt;br /&gt;
&lt;br /&gt;
# view/questionnaires/new.html.erb&lt;br /&gt;
# view/questionnaires/edit.html.erb&lt;br /&gt;
# view/questionnaires/view.html.erb&lt;br /&gt;
&lt;br /&gt;
The modifications made to the above files will be significant since the new rubric creation interface will be entirely different form the existing one. A lot of the code will have to be written from scratch.&lt;br /&gt;
== '''Implementation''' ==&lt;br /&gt;
To implement the drag-and-drop interface, we need to incorporate the source code from [https://github.com/kevinchappell/formBuilder/ GitHub] into our existing Expertiza project by adding them in &amp;quot;/vendor/assets/&amp;quot; folder.&lt;br /&gt;
&lt;br /&gt;
To intialize the jQuery formBuilder plugin, a file needs to be added under &amp;quot;/app/assets/javascripts/&amp;quot; folder named &amp;quot;form-init.js&amp;quot;. Within this file we need to specify the options to match our required form for rubric creation. The code for this is as follows :&lt;br /&gt;
&lt;br /&gt;
  fbOptions = {&lt;br /&gt;
  	    dataType: 'json',&lt;br /&gt;
  	    sortableControls: false,&lt;br /&gt;
  	    editOnAdd: false,&lt;br /&gt;
  	    stickyControls: true, &lt;br /&gt;
  	    sortableControls: false, &lt;br /&gt;
  	    disableFields: ['autocomplete', 'button','paragraph', 'number', 'checkbox-group', 'date', 'file', 'hidden', 'header'],  			     		    &lt;br /&gt;
  	    editOnAdd: false, &lt;br /&gt;
  	    showActionButtons: true, &lt;br /&gt;
  		defaultFields: defaultFields, // edit will load the fields from db&lt;br /&gt;
  		fieldRemoveWarn: true,&lt;br /&gt;
  	    typeUserEvents: {&lt;br /&gt;
  			'checkbox': onAddHandler,&lt;br /&gt;
  			'header': onAddHandler,&lt;br /&gt;
  			'radio-group': onAddHandler,&lt;br /&gt;
  			'select': onAddHandler,&lt;br /&gt;
  			'text': onAddHandler,&lt;br /&gt;
  			'textarea': onAddHandler&lt;br /&gt;
  	    }&lt;br /&gt;
  	};&lt;br /&gt;
    var formBuilder = $(buildWrap).formBuilder(fbOptions).data('formBuilder')&lt;br /&gt;
&lt;br /&gt;
[[File:Form.png|frame|upright|center|Sample Form using JQuery formBuilder]]&lt;br /&gt;
&lt;br /&gt;
== '''Testing Plan''' ==&lt;br /&gt;
&lt;br /&gt;
[[File:inst-flow.png | frame | upright | center | Instructor Flow Diagram]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
# Login as instructor (username: instructor6, password:password).&lt;br /&gt;
# Click on 'Questionnaires' tab present in the Manage section.&lt;br /&gt;
# Click on 'New public item' to go to the 'Create ReviewQuestionnaire&amp;quot; page.&lt;br /&gt;
# Click on 'Create' icon which will forward you to &amp;quot;form Builder&amp;quot; page.&lt;br /&gt;
# Now you can create a sample rubrics by dragging and dropping the form fields and configuring the field parameters.&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=106107</id>
		<title>CSC/ECE 517 Fall 2016/E1693. Drag-and-drop interface for creating rubrics</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=106107"/>
		<updated>2016-12-02T22:51:40Z</updated>

		<summary type="html">&lt;p&gt;Msardar: /* Implementation */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''Introduction to Expertiza''' ==&lt;br /&gt;
Expertiza is an online system that is used by students to view/submit assignments and review others' work. Expertiza also provides tools to visualize the scores and gauge the improvements made during the course semester. It also facilitates and monitors team projects. It is targeted at educational and non-profit organizations. &lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source project with the source code available as a public repository on GitHub. It is developed using Ruby on Rails and is increasingly becoming robust thanks to the innumerable bugs being fixed by the community. The project has a micro-blog on SourceForge where the developer community report bugs and document updates.&lt;br /&gt;
&lt;br /&gt;
=='''Problem Statement'''==&lt;br /&gt;
&lt;br /&gt;
The existing interface for defining rubric is not very user friendly. The instructors or TAs are required to define the type of the field, the dimension of the fields (length, height), and possibly the content of the widget e.g., available options for a combo box. Unfortunately, after they are done with the design phase, to see the final result of the rubric that is going to be presented to the students, they have to impersonate students, create a fake submissions, move the due dates etc. The existing rubrics creation page is shown in the Figure below.&lt;br /&gt;
&lt;br /&gt;
[[File:OldRubricPage.PNG|frame|upright|center|Old Rubric Creation Page]]&lt;br /&gt;
&lt;br /&gt;
As mentioned before, the above shown page is not very intuitive. Also the instructor has no idea how the page would appear to a student unless he logs in as a student, create submissions, etc. which is very time consuming. Hence a better design would be to create a rubrics page that would appear the same to the instructors and the students.&lt;br /&gt;
&lt;br /&gt;
We need to implement a WYSIWYG (What You See Is What You Get) UI for the rubric page to create rubrics which supports the following expertiza's question types:&lt;br /&gt;
&lt;br /&gt;
* Criterion&lt;br /&gt;
* Checkbox&lt;br /&gt;
* TextField&lt;br /&gt;
* Dropdown&lt;br /&gt;
* TextArea&lt;br /&gt;
* UploadFile&lt;br /&gt;
*  SectionHeader&lt;br /&gt;
* TableHeader&lt;br /&gt;
* ColumnHeader&lt;br /&gt;
* Scale&lt;br /&gt;
&lt;br /&gt;
== '''Design''' ==&lt;br /&gt;
To create the drag-and-drop interface, we can use the [https://formbuilder.online jQuery formBuilder plugin]. The 'jquery-rails' gem is already present in the Gemfile, so we only need to initialize the formBuilder plugin.&lt;br /&gt;
&lt;br /&gt;
The advantages of using this plugin are:&lt;br /&gt;
&lt;br /&gt;
* 100% client-side plugin that gives users the power to create forms using an intuitive drag and drop interface.&lt;br /&gt;
* Customization - enable only the fields you need, use your own notifications append or prepend content and more.&lt;br /&gt;
* Bootstrap ready but not dependent&lt;br /&gt;
&lt;br /&gt;
A mockup for an example form is given below:&lt;br /&gt;
&lt;br /&gt;
[[File:JQuery.png|frame|upright|center|Sample Form using JQuery formBuilder]]&lt;br /&gt;
&lt;br /&gt;
The above screenshot consists of two sections: main area to the left and the control section to the right. The control section consists of the various form fields which can be dragged and dropped to the main area. In the main area, the parameters to the fields can be configured including field length, options, values, etc. Hence the drag and drop interface will provide a very intuitive way for the instructor/TA to create rubrics and also view how the page would appear to a student. Moreover it provides the option to edit the field information when we create the individual fields. For example, in case of dropdown we can specify the options of the dropdown. A sample screenshot of text area creation is shown below.&lt;br /&gt;
&lt;br /&gt;
[[File:text_area.PNG|frame|upright|center|Text Area Creation]]&lt;br /&gt;
&lt;br /&gt;
In the above screenshot, we can see that we are creating a text area. There is an edit option at the top right corner of the field, clicking on which we get a form through which the options can be given. In the above case of creating a text area, we can specify the label, value, number of rows, the maximum of the characters, placeholder, help text, etc. We can also specify if the field is mandatory by checking the required checkbox given at the top of the form. In a similar way configuration options are available to all the form fields that can be created.&lt;br /&gt;
&lt;br /&gt;
== '''Files to be modified''' ==&lt;br /&gt;
This project only involves modifying the UI for instructors to create new rubrics. The rubric configurations stored in the database and the views from the student side will remain the same. Hence, no modifications need to be made to the questionnaire model or controller.&lt;br /&gt;
&lt;br /&gt;
All types of rubrics (Review, Metareview, Author Feedback, Teammate review, Survey, Course Evaluation etc.) are created and modified using the same views. These views exist in views/questionnaires folder. Hence the files to be modified to incorporate the new UI design will be:&lt;br /&gt;
&lt;br /&gt;
# view/questionnaires/new.html.erb&lt;br /&gt;
# view/questionnaires/edit.html.erb&lt;br /&gt;
# view/questionnaires/view.html.erb&lt;br /&gt;
&lt;br /&gt;
The modifications made to the above files will be significant since the new rubric creation interface will be entirely different form the existing one. A lot of the code will have to be written from scratch.&lt;br /&gt;
== '''Implementation''' ==&lt;br /&gt;
To implement the drag-and-drop interface, we need to incorporate the source code from [https://github.com/kevinchappell/formBuilder/ GitHub] into our existing Expertiza project by adding them in &amp;quot;/vendor/assets/&amp;quot; folder.&lt;br /&gt;
&lt;br /&gt;
To intialize the jQuery formBuilder plugin, a file needs to be added under &amp;quot;/app/assets/javascripts/&amp;quot; folder named &amp;quot;form-init.js&amp;quot;. Within this file we need to specify the options to match our required form for rubric creation. The code for this is as follows :&lt;br /&gt;
&lt;br /&gt;
  fbOptions = {&lt;br /&gt;
  	    dataType: 'json',&lt;br /&gt;
  	    sortableControls: false,&lt;br /&gt;
  	    editOnAdd: false,&lt;br /&gt;
  	    stickyControls: true, &lt;br /&gt;
  	    sortableControls: false, &lt;br /&gt;
  	    disableFields: ['autocomplete', 'button','paragraph', 'number', 'checkbox-group', 'date', 'file', 'hidden', 'header'],  			     		    &lt;br /&gt;
  	    editOnAdd: false, &lt;br /&gt;
  	    showActionButtons: true, &lt;br /&gt;
  		defaultFields: defaultFields, // edit will load the fields from db&lt;br /&gt;
  		fieldRemoveWarn: true,&lt;br /&gt;
  	    typeUserEvents: {&lt;br /&gt;
  			'checkbox': onAddHandler,&lt;br /&gt;
  			'header': onAddHandler,&lt;br /&gt;
  			'radio-group': onAddHandler,&lt;br /&gt;
  			'select': onAddHandler,&lt;br /&gt;
  			'text': onAddHandler,&lt;br /&gt;
  			'textarea': onAddHandler&lt;br /&gt;
  	    }&lt;br /&gt;
  	};&lt;br /&gt;
    var formBuilder = $(buildWrap).formBuilder(fbOptions).data('formBuilder')&lt;br /&gt;
&lt;br /&gt;
== '''Testing Plan''' ==&lt;br /&gt;
&lt;br /&gt;
[[File:inst-flow.png | frame | upright | center | Instructor Flow Diagram]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
# Login as instructor (username: instructor6, password:password).&lt;br /&gt;
# Click on 'Questionnaires' tab present in the Manage section.&lt;br /&gt;
# Click on 'New public item' to go to the 'Create ReviewQuestionnaire&amp;quot; page.&lt;br /&gt;
# Click on 'Create' icon which will forward you to &amp;quot;form Builder&amp;quot; page.&lt;br /&gt;
# Now you can create a sample rubrics by dragging and dropping the form fields and configuring the field parameters.&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=106106</id>
		<title>CSC/ECE 517 Fall 2016/E1693. Drag-and-drop interface for creating rubrics</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=106106"/>
		<updated>2016-12-02T22:50:57Z</updated>

		<summary type="html">&lt;p&gt;Msardar: /* Implementation */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''Introduction to Expertiza''' ==&lt;br /&gt;
Expertiza is an online system that is used by students to view/submit assignments and review others' work. Expertiza also provides tools to visualize the scores and gauge the improvements made during the course semester. It also facilitates and monitors team projects. It is targeted at educational and non-profit organizations. &lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source project with the source code available as a public repository on GitHub. It is developed using Ruby on Rails and is increasingly becoming robust thanks to the innumerable bugs being fixed by the community. The project has a micro-blog on SourceForge where the developer community report bugs and document updates.&lt;br /&gt;
&lt;br /&gt;
=='''Problem Statement'''==&lt;br /&gt;
&lt;br /&gt;
The existing interface for defining rubric is not very user friendly. The instructors or TAs are required to define the type of the field, the dimension of the fields (length, height), and possibly the content of the widget e.g., available options for a combo box. Unfortunately, after they are done with the design phase, to see the final result of the rubric that is going to be presented to the students, they have to impersonate students, create a fake submissions, move the due dates etc. The existing rubrics creation page is shown in the Figure below.&lt;br /&gt;
&lt;br /&gt;
[[File:OldRubricPage.PNG|frame|upright|center|Old Rubric Creation Page]]&lt;br /&gt;
&lt;br /&gt;
As mentioned before, the above shown page is not very intuitive. Also the instructor has no idea how the page would appear to a student unless he logs in as a student, create submissions, etc. which is very time consuming. Hence a better design would be to create a rubrics page that would appear the same to the instructors and the students.&lt;br /&gt;
&lt;br /&gt;
We need to implement a WYSIWYG (What You See Is What You Get) UI for the rubric page to create rubrics which supports the following expertiza's question types:&lt;br /&gt;
&lt;br /&gt;
* Criterion&lt;br /&gt;
* Checkbox&lt;br /&gt;
* TextField&lt;br /&gt;
* Dropdown&lt;br /&gt;
* TextArea&lt;br /&gt;
* UploadFile&lt;br /&gt;
*  SectionHeader&lt;br /&gt;
* TableHeader&lt;br /&gt;
* ColumnHeader&lt;br /&gt;
* Scale&lt;br /&gt;
&lt;br /&gt;
== '''Design''' ==&lt;br /&gt;
To create the drag-and-drop interface, we can use the [https://formbuilder.online jQuery formBuilder plugin]. The 'jquery-rails' gem is already present in the Gemfile, so we only need to initialize the formBuilder plugin.&lt;br /&gt;
&lt;br /&gt;
The advantages of using this plugin are:&lt;br /&gt;
&lt;br /&gt;
* 100% client-side plugin that gives users the power to create forms using an intuitive drag and drop interface.&lt;br /&gt;
* Customization - enable only the fields you need, use your own notifications append or prepend content and more.&lt;br /&gt;
* Bootstrap ready but not dependent&lt;br /&gt;
&lt;br /&gt;
A mockup for an example form is given below:&lt;br /&gt;
&lt;br /&gt;
[[File:JQuery.png|frame|upright|center|Sample Form using JQuery formBuilder]]&lt;br /&gt;
&lt;br /&gt;
The above screenshot consists of two sections: main area to the left and the control section to the right. The control section consists of the various form fields which can be dragged and dropped to the main area. In the main area, the parameters to the fields can be configured including field length, options, values, etc. Hence the drag and drop interface will provide a very intuitive way for the instructor/TA to create rubrics and also view how the page would appear to a student. Moreover it provides the option to edit the field information when we create the individual fields. For example, in case of dropdown we can specify the options of the dropdown. A sample screenshot of text area creation is shown below.&lt;br /&gt;
&lt;br /&gt;
[[File:text_area.PNG|frame|upright|center|Text Area Creation]]&lt;br /&gt;
&lt;br /&gt;
In the above screenshot, we can see that we are creating a text area. There is an edit option at the top right corner of the field, clicking on which we get a form through which the options can be given. In the above case of creating a text area, we can specify the label, value, number of rows, the maximum of the characters, placeholder, help text, etc. We can also specify if the field is mandatory by checking the required checkbox given at the top of the form. In a similar way configuration options are available to all the form fields that can be created.&lt;br /&gt;
&lt;br /&gt;
== '''Files to be modified''' ==&lt;br /&gt;
This project only involves modifying the UI for instructors to create new rubrics. The rubric configurations stored in the database and the views from the student side will remain the same. Hence, no modifications need to be made to the questionnaire model or controller.&lt;br /&gt;
&lt;br /&gt;
All types of rubrics (Review, Metareview, Author Feedback, Teammate review, Survey, Course Evaluation etc.) are created and modified using the same views. These views exist in views/questionnaires folder. Hence the files to be modified to incorporate the new UI design will be:&lt;br /&gt;
&lt;br /&gt;
# view/questionnaires/new.html.erb&lt;br /&gt;
# view/questionnaires/edit.html.erb&lt;br /&gt;
# view/questionnaires/view.html.erb&lt;br /&gt;
&lt;br /&gt;
The modifications made to the above files will be significant since the new rubric creation interface will be entirely different form the existing one. A lot of the code will have to be written from scratch.&lt;br /&gt;
== '''Implementation''' ==&lt;br /&gt;
To implement the drag-and-drop interface, we need to incorporate the source code from [https://github.com/kevinchappell/formBuilder/] into our existing Expertiza project by adding them in &amp;quot;/vendor/assets/&amp;quot; folder.&lt;br /&gt;
&lt;br /&gt;
To intialize the jQuery formBuilder plugin, a file needs to be added under &amp;quot;/app/assets/javascripts/&amp;quot; folder named &amp;quot;form-init.js&amp;quot;. Within this file we need to specify the options to match our required form for rubric creation. The code for this is as follows :&lt;br /&gt;
&lt;br /&gt;
  fbOptions = {&lt;br /&gt;
  	    dataType: 'json',&lt;br /&gt;
  	    sortableControls: false,&lt;br /&gt;
  	    editOnAdd: false,&lt;br /&gt;
  	    stickyControls: true, &lt;br /&gt;
  	    sortableControls: false, &lt;br /&gt;
  	    disableFields: ['autocomplete', 'button','paragraph', 'number', 'checkbox-group', 'date', 'file', 'hidden', 'header'],  			     		    &lt;br /&gt;
  	    editOnAdd: false, &lt;br /&gt;
  	    showActionButtons: true, &lt;br /&gt;
  		defaultFields: defaultFields, // edit will load the fields from db&lt;br /&gt;
  		fieldRemoveWarn: true,&lt;br /&gt;
  	    typeUserEvents: {&lt;br /&gt;
  			'checkbox': onAddHandler,&lt;br /&gt;
  			'header': onAddHandler,&lt;br /&gt;
  			'radio-group': onAddHandler,&lt;br /&gt;
  			'select': onAddHandler,&lt;br /&gt;
  			'text': onAddHandler,&lt;br /&gt;
  			'textarea': onAddHandler&lt;br /&gt;
  	    }&lt;br /&gt;
  	};&lt;br /&gt;
    var formBuilder = $(buildWrap).formBuilder(fbOptions).data('formBuilder')&lt;br /&gt;
&lt;br /&gt;
== '''Testing Plan''' ==&lt;br /&gt;
&lt;br /&gt;
[[File:inst-flow.png | frame | upright | center | Instructor Flow Diagram]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
# Login as instructor (username: instructor6, password:password).&lt;br /&gt;
# Click on 'Questionnaires' tab present in the Manage section.&lt;br /&gt;
# Click on 'New public item' to go to the 'Create ReviewQuestionnaire&amp;quot; page.&lt;br /&gt;
# Click on 'Create' icon which will forward you to &amp;quot;form Builder&amp;quot; page.&lt;br /&gt;
# Now you can create a sample rubrics by dragging and dropping the form fields and configuring the field parameters.&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=106102</id>
		<title>CSC/ECE 517 Fall 2016/E1693. Drag-and-drop interface for creating rubrics</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=106102"/>
		<updated>2016-12-02T22:44:40Z</updated>

		<summary type="html">&lt;p&gt;Msardar: /* Implementation */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''Introduction to Expertiza''' ==&lt;br /&gt;
Expertiza is an online system that is used by students to view/submit assignments and review others' work. Expertiza also provides tools to visualize the scores and gauge the improvements made during the course semester. It also facilitates and monitors team projects. It is targeted at educational and non-profit organizations. &lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source project with the source code available as a public repository on GitHub. It is developed using Ruby on Rails and is increasingly becoming robust thanks to the innumerable bugs being fixed by the community. The project has a micro-blog on SourceForge where the developer community report bugs and document updates.&lt;br /&gt;
&lt;br /&gt;
=='''Problem Statement'''==&lt;br /&gt;
&lt;br /&gt;
The existing interface for defining rubric is not very user friendly. The instructors or TAs are required to define the type of the field, the dimension of the fields (length, height), and possibly the content of the widget e.g., available options for a combo box. Unfortunately, after they are done with the design phase, to see the final result of the rubric that is going to be presented to the students, they have to impersonate students, create a fake submissions, move the due dates etc. The existing rubrics creation page is shown in the Figure below.&lt;br /&gt;
&lt;br /&gt;
[[File:OldRubricPage.PNG|frame|upright|center|Old Rubric Creation Page]]&lt;br /&gt;
&lt;br /&gt;
As mentioned before, the above shown page is not very intuitive. Also the instructor has no idea how the page would appear to a student unless he logs in as a student, create submissions, etc. which is very time consuming. Hence a better design would be to create a rubrics page that would appear the same to the instructors and the students.&lt;br /&gt;
&lt;br /&gt;
We need to implement a WYSIWYG (What You See Is What You Get) UI for the rubric page to create rubrics which supports the following expertiza's question types:&lt;br /&gt;
&lt;br /&gt;
* Criterion&lt;br /&gt;
* Checkbox&lt;br /&gt;
* TextField&lt;br /&gt;
* Dropdown&lt;br /&gt;
* TextArea&lt;br /&gt;
* UploadFile&lt;br /&gt;
*  SectionHeader&lt;br /&gt;
* TableHeader&lt;br /&gt;
* ColumnHeader&lt;br /&gt;
* Scale&lt;br /&gt;
&lt;br /&gt;
== '''Design''' ==&lt;br /&gt;
To create the drag-and-drop interface, we can use the [https://formbuilder.online jQuery formBuilder plugin]. The 'jquery-rails' gem is already present in the Gemfile, so we only need to initialize the formBuilder plugin.&lt;br /&gt;
&lt;br /&gt;
The advantages of using this plugin are:&lt;br /&gt;
&lt;br /&gt;
* 100% client-side plugin that gives users the power to create forms using an intuitive drag and drop interface.&lt;br /&gt;
* Customization - enable only the fields you need, use your own notifications append or prepend content and more.&lt;br /&gt;
* Bootstrap ready but not dependent&lt;br /&gt;
&lt;br /&gt;
A mockup for an example form is given below:&lt;br /&gt;
&lt;br /&gt;
[[File:JQuery.png|frame|upright|center|Sample Form using JQuery formBuilder]]&lt;br /&gt;
&lt;br /&gt;
The above screenshot consists of two sections: main area to the left and the control section to the right. The control section consists of the various form fields which can be dragged and dropped to the main area. In the main area, the parameters to the fields can be configured including field length, options, values, etc. Hence the drag and drop interface will provide a very intuitive way for the instructor/TA to create rubrics and also view how the page would appear to a student. Moreover it provides the option to edit the field information when we create the individual fields. For example, in case of dropdown we can specify the options of the dropdown. A sample screenshot of text area creation is shown below.&lt;br /&gt;
&lt;br /&gt;
[[File:text_area.PNG|frame|upright|center|Text Area Creation]]&lt;br /&gt;
&lt;br /&gt;
In the above screenshot, we can see that we are creating a text area. There is an edit option at the top right corner of the field, clicking on which we get a form through which the options can be given. In the above case of creating a text area, we can specify the label, value, number of rows, the maximum of the characters, placeholder, help text, etc. We can also specify if the field is mandatory by checking the required checkbox given at the top of the form. In a similar way configuration options are available to all the form fields that can be created.&lt;br /&gt;
&lt;br /&gt;
== '''Files to be modified''' ==&lt;br /&gt;
This project only involves modifying the UI for instructors to create new rubrics. The rubric configurations stored in the database and the views from the student side will remain the same. Hence, no modifications need to be made to the questionnaire model or controller.&lt;br /&gt;
&lt;br /&gt;
All types of rubrics (Review, Metareview, Author Feedback, Teammate review, Survey, Course Evaluation etc.) are created and modified using the same views. These views exist in views/questionnaires folder. Hence the files to be modified to incorporate the new UI design will be:&lt;br /&gt;
&lt;br /&gt;
# view/questionnaires/new.html.erb&lt;br /&gt;
# view/questionnaires/edit.html.erb&lt;br /&gt;
# view/questionnaires/view.html.erb&lt;br /&gt;
&lt;br /&gt;
The modifications made to the above files will be significant since the new rubric creation interface will be entirely different form the existing one. A lot of the code will have to be written from scratch.&lt;br /&gt;
== '''Implementation''' ==&lt;br /&gt;
To intialize the jQuery formBuilder plugin, a file needs to be added under &amp;quot;app/assets/javascripts&amp;quot; folder named &amp;quot;form-init.js&amp;quot;. Within this file we need to specify the options to match our required form for rubric creation. The code for this is as follows :&lt;br /&gt;
&lt;br /&gt;
  fbOptions = {&lt;br /&gt;
  	    dataType: 'json',&lt;br /&gt;
  	    sortableControls: false,&lt;br /&gt;
  	    editOnAdd: false,&lt;br /&gt;
  	    stickyControls: true, &lt;br /&gt;
  	    sortableControls: false, &lt;br /&gt;
  	    disableFields: ['autocomplete', 'button','paragraph', 'number', 'checkbox-group', 'date', 'file', 'hidden', 'header'],  			     		    &lt;br /&gt;
  	    editOnAdd: false, &lt;br /&gt;
  	    showActionButtons: true, &lt;br /&gt;
  		defaultFields: defaultFields, // edit will load the fields from db&lt;br /&gt;
  		fieldRemoveWarn: true,&lt;br /&gt;
  	    typeUserEvents: {&lt;br /&gt;
  			'checkbox': onAddHandler,&lt;br /&gt;
  			'header': onAddHandler,&lt;br /&gt;
  			'radio-group': onAddHandler,&lt;br /&gt;
  			'select': onAddHandler,&lt;br /&gt;
  			'text': onAddHandler,&lt;br /&gt;
  			'textarea': onAddHandler&lt;br /&gt;
  	    }&lt;br /&gt;
  	};&lt;br /&gt;
    var formBuilder = $(buildWrap).formBuilder(fbOptions).data('formBuilder')&lt;br /&gt;
&lt;br /&gt;
== '''Testing Plan''' ==&lt;br /&gt;
&lt;br /&gt;
[[File:inst-flow.png | frame | upright | center | Instructor Flow Diagram]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
# Login as instructor (username: instructor6, password:password).&lt;br /&gt;
# Click on 'Questionnaires' tab present in the Manage section.&lt;br /&gt;
# Click on 'New public item' to go to the 'Create ReviewQuestionnaire&amp;quot; page.&lt;br /&gt;
# Click on 'Create' icon which will forward you to &amp;quot;form Builder&amp;quot; page.&lt;br /&gt;
# Now you can create a sample rubrics by dragging and dropping the form fields and configuring the field parameters.&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=106101</id>
		<title>CSC/ECE 517 Fall 2016/E1693. Drag-and-drop interface for creating rubrics</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=106101"/>
		<updated>2016-12-02T22:43:52Z</updated>

		<summary type="html">&lt;p&gt;Msardar: /* Implementation */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''Introduction to Expertiza''' ==&lt;br /&gt;
Expertiza is an online system that is used by students to view/submit assignments and review others' work. Expertiza also provides tools to visualize the scores and gauge the improvements made during the course semester. It also facilitates and monitors team projects. It is targeted at educational and non-profit organizations. &lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source project with the source code available as a public repository on GitHub. It is developed using Ruby on Rails and is increasingly becoming robust thanks to the innumerable bugs being fixed by the community. The project has a micro-blog on SourceForge where the developer community report bugs and document updates.&lt;br /&gt;
&lt;br /&gt;
=='''Problem Statement'''==&lt;br /&gt;
&lt;br /&gt;
The existing interface for defining rubric is not very user friendly. The instructors or TAs are required to define the type of the field, the dimension of the fields (length, height), and possibly the content of the widget e.g., available options for a combo box. Unfortunately, after they are done with the design phase, to see the final result of the rubric that is going to be presented to the students, they have to impersonate students, create a fake submissions, move the due dates etc. The existing rubrics creation page is shown in the Figure below.&lt;br /&gt;
&lt;br /&gt;
[[File:OldRubricPage.PNG|frame|upright|center|Old Rubric Creation Page]]&lt;br /&gt;
&lt;br /&gt;
As mentioned before, the above shown page is not very intuitive. Also the instructor has no idea how the page would appear to a student unless he logs in as a student, create submissions, etc. which is very time consuming. Hence a better design would be to create a rubrics page that would appear the same to the instructors and the students.&lt;br /&gt;
&lt;br /&gt;
We need to implement a WYSIWYG (What You See Is What You Get) UI for the rubric page to create rubrics which supports the following expertiza's question types:&lt;br /&gt;
&lt;br /&gt;
* Criterion&lt;br /&gt;
* Checkbox&lt;br /&gt;
* TextField&lt;br /&gt;
* Dropdown&lt;br /&gt;
* TextArea&lt;br /&gt;
* UploadFile&lt;br /&gt;
*  SectionHeader&lt;br /&gt;
* TableHeader&lt;br /&gt;
* ColumnHeader&lt;br /&gt;
* Scale&lt;br /&gt;
&lt;br /&gt;
== '''Design''' ==&lt;br /&gt;
To create the drag-and-drop interface, we can use the [https://formbuilder.online jQuery formBuilder plugin]. The 'jquery-rails' gem is already present in the Gemfile, so we only need to initialize the formBuilder plugin.&lt;br /&gt;
&lt;br /&gt;
The advantages of using this plugin are:&lt;br /&gt;
&lt;br /&gt;
* 100% client-side plugin that gives users the power to create forms using an intuitive drag and drop interface.&lt;br /&gt;
* Customization - enable only the fields you need, use your own notifications append or prepend content and more.&lt;br /&gt;
* Bootstrap ready but not dependent&lt;br /&gt;
&lt;br /&gt;
A mockup for an example form is given below:&lt;br /&gt;
&lt;br /&gt;
[[File:JQuery.png|frame|upright|center|Sample Form using JQuery formBuilder]]&lt;br /&gt;
&lt;br /&gt;
The above screenshot consists of two sections: main area to the left and the control section to the right. The control section consists of the various form fields which can be dragged and dropped to the main area. In the main area, the parameters to the fields can be configured including field length, options, values, etc. Hence the drag and drop interface will provide a very intuitive way for the instructor/TA to create rubrics and also view how the page would appear to a student. Moreover it provides the option to edit the field information when we create the individual fields. For example, in case of dropdown we can specify the options of the dropdown. A sample screenshot of text area creation is shown below.&lt;br /&gt;
&lt;br /&gt;
[[File:text_area.PNG|frame|upright|center|Text Area Creation]]&lt;br /&gt;
&lt;br /&gt;
In the above screenshot, we can see that we are creating a text area. There is an edit option at the top right corner of the field, clicking on which we get a form through which the options can be given. In the above case of creating a text area, we can specify the label, value, number of rows, the maximum of the characters, placeholder, help text, etc. We can also specify if the field is mandatory by checking the required checkbox given at the top of the form. In a similar way configuration options are available to all the form fields that can be created.&lt;br /&gt;
&lt;br /&gt;
== '''Files to be modified''' ==&lt;br /&gt;
This project only involves modifying the UI for instructors to create new rubrics. The rubric configurations stored in the database and the views from the student side will remain the same. Hence, no modifications need to be made to the questionnaire model or controller.&lt;br /&gt;
&lt;br /&gt;
All types of rubrics (Review, Metareview, Author Feedback, Teammate review, Survey, Course Evaluation etc.) are created and modified using the same views. These views exist in views/questionnaires folder. Hence the files to be modified to incorporate the new UI design will be:&lt;br /&gt;
&lt;br /&gt;
# view/questionnaires/new.html.erb&lt;br /&gt;
# view/questionnaires/edit.html.erb&lt;br /&gt;
# view/questionnaires/view.html.erb&lt;br /&gt;
&lt;br /&gt;
The modifications made to the above files will be significant since the new rubric creation interface will be entirely different form the existing one. A lot of the code will have to be written from scratch.&lt;br /&gt;
== '''Implementation''' ==&lt;br /&gt;
To intialize the jQuery formBuilder plugin, a file needs to be added under &amp;quot;app/assets/javascripts&amp;quot; folder named &amp;quot;form-init.js&amp;quot;. Within this file we need to specify the options to match our required form for rubrics. The code for this is as follows :&lt;br /&gt;
&lt;br /&gt;
  fbOptions = {&lt;br /&gt;
  	    dataType: 'json',&lt;br /&gt;
  	    sortableControls: false,&lt;br /&gt;
  	    editOnAdd: false,&lt;br /&gt;
  	    stickyControls: true, &lt;br /&gt;
  	    sortableControls: false, &lt;br /&gt;
  	    disableFields: ['autocomplete', 'button','paragraph', 'number', 'checkbox-group', 'date', 'file', 'hidden', 'header'],  			     		    &lt;br /&gt;
  	    editOnAdd: false, &lt;br /&gt;
  	    showActionButtons: true, &lt;br /&gt;
  		defaultFields: defaultFields, // edit will load the fields from db&lt;br /&gt;
  		fieldRemoveWarn: true,&lt;br /&gt;
  	    typeUserEvents: {&lt;br /&gt;
  			'checkbox': onAddHandler,&lt;br /&gt;
  			'header': onAddHandler,&lt;br /&gt;
  			'radio-group': onAddHandler,&lt;br /&gt;
  			'select': onAddHandler,&lt;br /&gt;
  			'text': onAddHandler,&lt;br /&gt;
  			'textarea': onAddHandler&lt;br /&gt;
  	    }&lt;br /&gt;
  	};&lt;br /&gt;
    var formBuilder = $(buildWrap).formBuilder(fbOptions).data('formBuilder')&lt;br /&gt;
&lt;br /&gt;
== '''Testing Plan''' ==&lt;br /&gt;
&lt;br /&gt;
[[File:inst-flow.png | frame | upright | center | Instructor Flow Diagram]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
# Login as instructor (username: instructor6, password:password).&lt;br /&gt;
# Click on 'Questionnaires' tab present in the Manage section.&lt;br /&gt;
# Click on 'New public item' to go to the 'Create ReviewQuestionnaire&amp;quot; page.&lt;br /&gt;
# Click on 'Create' icon which will forward you to &amp;quot;form Builder&amp;quot; page.&lt;br /&gt;
# Now you can create a sample rubrics by dragging and dropping the form fields and configuring the field parameters.&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=105696</id>
		<title>CSC/ECE 517 Fall 2016/E1693. Drag-and-drop interface for creating rubrics</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=105696"/>
		<updated>2016-11-14T22:55:02Z</updated>

		<summary type="html">&lt;p&gt;Msardar: /* Files to be modified */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''Introduction to Expertiza''' ==&lt;br /&gt;
Expertiza is an online system that is used by students to view/submit assignments and review others' work. Expertiza also provides tools to visualize the scores and gauge the improvements made during the course semester. It also facilitates and monitors team projects. It is targeted at educational and non-profit organizations. &lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source project with the source code available as a public repository on GitHub. It is developed using Ruby on Rails and is increasingly becoming robust thanks to the innumerable bugs being fixed by the community. The project has a micro-blog on SourceForge where the developer community report bugs and document updates.&lt;br /&gt;
&lt;br /&gt;
=='''Problem Statement'''==&lt;br /&gt;
&lt;br /&gt;
The existing interface for defining rubric is not very user friendly. The instructors or TAs are required to define the type of the field, the dimension of the fields (length, height), and possibly the content of the widget e.g., available options for a combo box. Unfortunately, after they are done with the design phase, to see the final result of the rubric that is going to be presented to the students, they have to impersonate students, create a fake submissions, move the due dates etc. The existing rubrics creation page is shown in the Figure below.&lt;br /&gt;
&lt;br /&gt;
[[File:OldRubricPage.PNG|frame|upright|center|Old Rubric Creation Page]]&lt;br /&gt;
&lt;br /&gt;
We need to implement a WYSIWYG (What You See Is What You Get) UI for the rubric page to create rubrics which supports the following expertiza's question types:&lt;br /&gt;
&lt;br /&gt;
* Criterion&lt;br /&gt;
* Checkbox&lt;br /&gt;
* TextField&lt;br /&gt;
* Dropdown&lt;br /&gt;
* TextArea&lt;br /&gt;
* UploadFile&lt;br /&gt;
*  SectionHeader&lt;br /&gt;
* TableHeader&lt;br /&gt;
* ColumnHeader&lt;br /&gt;
* Scale&lt;br /&gt;
&lt;br /&gt;
== '''Design''' ==&lt;br /&gt;
To create the drag-and-drop interface, we can use the [https://formbuilder.online jQuery formBuilder plugin]. The 'jquery-rails' gem is already present in the Gemfile, so we only need to initialize the formBuilder plugin.&lt;br /&gt;
&lt;br /&gt;
The advantages of using this plugin are:&lt;br /&gt;
&lt;br /&gt;
* 100% client-side plugin that gives users the power to create forms using an intuitive drag and drop interface.&lt;br /&gt;
* Customization - enable only the fields you need, use your own notifications append or prepend content and more.&lt;br /&gt;
* Bootstrap ready but not dependent&lt;br /&gt;
&lt;br /&gt;
A mockup for an example form is given below:&lt;br /&gt;
&lt;br /&gt;
[[File:JQuery.png|frame|upright|center|Sample Form using JQuery formBuilder]]&lt;br /&gt;
&lt;br /&gt;
The above screenshot consists of two sections: main area to the left and the control section to the right. The control section consists of the various form fields which can be dragged and dropped to the main area. In the main area, the parameters to the fields can be configured including field length, options, values, etc. Hence the drag and drop interface will provide a very intuitive way for the instructor/TA to create rubrics and also view how the page would appear to a student. Moreover it provides the option to edit the field information when we create the individual fields. For example, in case of dropdown we can specify the options of the dropdown. A sample screenshot of text area creation is shown below.&lt;br /&gt;
&lt;br /&gt;
[[File:text_area.PNG|frame|upright|center|Creation of Text Area]]&lt;br /&gt;
&lt;br /&gt;
In the above screenshot, we can see that we are creating a text area. There is an edit option at the top right corner of the field, clicking on which we get a form through which the options can be given. In the above case of creating a text area, we can specify the label, value, number of rows, the maximum of the characters, placeholder, help text, etc. We can also specify if the field is mandatory by checking the required checkbox given at the top of the form.&lt;br /&gt;
&lt;br /&gt;
== '''Files to be modified''' ==&lt;br /&gt;
This project only involves modifying the UI for instructors to create new rubrics. The rubric configurations stored in the database and the views from the student side will remain the same. Hence, no modifications need to be made to the questionnaire model or controller.&lt;br /&gt;
&lt;br /&gt;
All types of rubrics (Review, Metareview, Author Feedback, Teammate review, Survey, Course Evaluation etc.) are created and modified using the same views. These views exist in views/questionnaires folder. Hence the files to be modified to incorporate the new UI design will be:&lt;br /&gt;
&lt;br /&gt;
# view/questionnaires/new.html.erb&lt;br /&gt;
# view/questionnaires/edit.html.erb&lt;br /&gt;
# view/questionnaires/view.html.erb&lt;br /&gt;
&lt;br /&gt;
The modifications made to the above files will be significant since the new rubric creation interface will be entirely different form the existing one. A lot of the code will have to be written from scratch.&lt;br /&gt;
&lt;br /&gt;
== '''Testing Plan''' ==&lt;br /&gt;
# Login as instructor (username: instructor6).&lt;br /&gt;
# Click on 'Questionnaires' tab present in the Manage section.&lt;br /&gt;
# Click on 'New public item' to go to the 'Create ReviewQuestionnaire&amp;quot; page.&lt;br /&gt;
# Click on 'Create' icon which will forward you to &amp;quot;form Builder&amp;quot; page.&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=105682</id>
		<title>CSC/ECE 517 Fall 2016/E1693. Drag-and-drop interface for creating rubrics</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=105682"/>
		<updated>2016-11-14T22:48:02Z</updated>

		<summary type="html">&lt;p&gt;Msardar: /* Design */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''Introduction to Expertiza''' ==&lt;br /&gt;
Expertiza is an online system that is used by students to view/submit assignments and review others' work. Expertiza also provides tools to visualize the scores and gauge the improvements made during the course semester. It also facilitates and monitors team projects. It is targeted at educational and non-profit organizations. &lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source project with the source code available as a public repository on GitHub. It is developed using Ruby on Rails and is increasingly becoming robust thanks to the innumerable bugs being fixed by the community. The project has a micro-blog on SourceForge where the developer community report bugs and document updates.&lt;br /&gt;
&lt;br /&gt;
=='''Problem Statement'''==&lt;br /&gt;
&lt;br /&gt;
The existing interface for defining rubric is not very user friendly. The instructors or TAs are required to define the type of the field, the dimension of the fields (length, height), and possibly the content of the widget e.g., available options for a combo box. Unfortunately, after they are done with the design phase, to see the final result of the rubric that is going to be presented to the students, they have to impersonate students, create a fake submissions, move the due dates etc. The existing rubrics creation page is shown in the Figure below.&lt;br /&gt;
&lt;br /&gt;
[[File:OldRubricPage.PNG|frame|upright|center|Old Rubric Creation Page]]&lt;br /&gt;
&lt;br /&gt;
We need to implement a WYSIWYG (What You See Is What You Get) UI for the rubric page to create rubrics which supports the following expertiza's question types:&lt;br /&gt;
&lt;br /&gt;
* Criterion&lt;br /&gt;
* Checkbox&lt;br /&gt;
* TextField&lt;br /&gt;
* Dropdown&lt;br /&gt;
* TextArea&lt;br /&gt;
* UploadFile&lt;br /&gt;
*  SectionHeader&lt;br /&gt;
* TableHeader&lt;br /&gt;
* ColumnHeader&lt;br /&gt;
* Scale&lt;br /&gt;
&lt;br /&gt;
== '''Design''' ==&lt;br /&gt;
To create the drag-and-drop interface, we can use the [https://formbuilder.online jQuery formBuilder plugin]. The 'jquery-rails' gem is already present in the Gemfile, so we only need to initialize the formBuilder plugin.&lt;br /&gt;
&lt;br /&gt;
The advantages of using this plugin are:&lt;br /&gt;
&lt;br /&gt;
* 100% client-side plugin that gives users the power to create forms using an intuitive drag and drop interface.&lt;br /&gt;
* Customization - enable only the fields you need, use your own notifications append or prepend content and more.&lt;br /&gt;
* Bootstrap ready but not dependent&lt;br /&gt;
&lt;br /&gt;
A mockup for an example form is given below:&lt;br /&gt;
&lt;br /&gt;
[[File:JQuery.png|frame|upright|center|Sample Form using JQuery formBuilder]]&lt;br /&gt;
&lt;br /&gt;
The above screenshot consists of two sections: main area to the left and the control section to the right. The control section consists of the various form fields which can be dragged and dropped to the main area. In the main area, the parameters to the fields can be configured including field length, options, values, etc. Hence the drag and drop interface will provide a very intuitive way for the instructor/TA to create rubrics and also view how the page would appear to a student.&lt;br /&gt;
&lt;br /&gt;
[[File:text_area.PNG|frame|upright|center|Creation of Text Area]]&lt;br /&gt;
&lt;br /&gt;
== '''Files to be modified''' ==&lt;br /&gt;
This project only involves modifying the UI for instructors to create new rubrics. The rubric configurations stored in the database and the views from the student side will remain the same. Hence, no modifications need to be made to the questionnaire model or controller.&lt;br /&gt;
&lt;br /&gt;
All types of rubrics (Review, Metareview, Author Feedback, Teammate review, Survey, Course Evaluation etc.) are created and modified using the same views. These views exist in views/questionnaires folder. Hence the files to be modified to incorporate the new UI design will be:&lt;br /&gt;
&lt;br /&gt;
* view/questionnaires/new.html.erb&lt;br /&gt;
* view/questionnaires/edit.html.erb&lt;br /&gt;
* view/questionnaires/view.html.erb&lt;br /&gt;
&lt;br /&gt;
The modifications made to the above files will be significant since the new rubric creation interface will be entirely different form the existing one. A lot of the code will have to be written from scratch.&lt;br /&gt;
&lt;br /&gt;
== '''Testing Plan''' ==&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Text_area.PNG&amp;diff=105679</id>
		<title>File:Text area.PNG</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Text_area.PNG&amp;diff=105679"/>
		<updated>2016-11-14T22:46:56Z</updated>

		<summary type="html">&lt;p&gt;Msardar: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=105677</id>
		<title>CSC/ECE 517 Fall 2016/E1693. Drag-and-drop interface for creating rubrics</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=105677"/>
		<updated>2016-11-14T22:41:48Z</updated>

		<summary type="html">&lt;p&gt;Msardar: /* Design */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''Introduction to Expertiza''' ==&lt;br /&gt;
Expertiza is an online system that is used by students to view/submit assignments and review others' work. Expertiza also provides tools to visualize the scores and gauge the improvements made during the course semester. It also facilitates and monitors team projects. It is targeted at educational and non-profit organizations. &lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source project with the source code available as a public repository on GitHub. It is developed using Ruby on Rails and is increasingly becoming robust thanks to the innumerable bugs being fixed by the community. The project has a micro-blog on SourceForge where the developer community report bugs and document updates.&lt;br /&gt;
&lt;br /&gt;
=='''Problem Statement'''==&lt;br /&gt;
&lt;br /&gt;
The existing interface for defining rubric is not very user friendly. The instructors or TAs are required to define the type of the field, the dimension of the fields (length, height), and possibly the content of the widget e.g., available options for a combo box. Unfortunately, after they are done with the design phase, to see the final result of the rubric that is going to be presented to the students, they have to impersonate students, create a fake submissions, move the due dates etc. The existing rubrics creation page is shown in the Figure below.&lt;br /&gt;
&lt;br /&gt;
[[File:OldRubricPage.PNG|frame|upright|center|Old Rubric Creation Page]]&lt;br /&gt;
&lt;br /&gt;
We need to implement a WYSIWYG (What You See Is What You Get) UI for the rubric page to create rubrics which supports the following expertiza's question types:&lt;br /&gt;
&lt;br /&gt;
* Criterion&lt;br /&gt;
* Checkbox&lt;br /&gt;
* TextField&lt;br /&gt;
* Dropdown&lt;br /&gt;
* TextArea&lt;br /&gt;
* UploadFile&lt;br /&gt;
*  SectionHeader&lt;br /&gt;
* TableHeader&lt;br /&gt;
* ColumnHeader&lt;br /&gt;
* Scale&lt;br /&gt;
&lt;br /&gt;
== '''Design''' ==&lt;br /&gt;
To create the drag-and-drop interface, we can use the [https://formbuilder.online jQuery formBuilder plugin]. The 'jquery-rails' gem is already present in the Gemfile, so we only need to initialize the formBuilder plugin.&lt;br /&gt;
&lt;br /&gt;
The advantages of using this plugin are:&lt;br /&gt;
&lt;br /&gt;
* 100% client-side plugin that gives users the power to create forms using an intuitive drag and drop interface.&lt;br /&gt;
* Customization - enable only the fields you need, use your own notifications append or prepend content and more.&lt;br /&gt;
* Bootstrap ready but not dependent&lt;br /&gt;
&lt;br /&gt;
A mockup for an example form is given below:&lt;br /&gt;
&lt;br /&gt;
[[File:JQuery.png|frame|upright|center|Sample Form using JQuery formBuilder]]&lt;br /&gt;
&lt;br /&gt;
The above screenshot consists of two sections: main area to the left and the control section to the right. The control section consists of the various form fields which can be dragged and dropped to the main area. In the main area, the parameters to the fields can be configured including field length, options, values, etc. Hence the drag and drop interface will provide a very intuitive way for the instructor/TA to create rubrics and also view how the page would appear to a student.&lt;br /&gt;
&lt;br /&gt;
== '''Files to be modified''' ==&lt;br /&gt;
This project only involves modifying the UI for instructors to create new rubrics. The rubric configurations stored in the database and the views from the student side will remain the same. Hence, no modifications need to be made to the questionnaire model or controller.&lt;br /&gt;
&lt;br /&gt;
All types of rubrics (Review, Metareview, Author Feedback, Teammate review, Survey, Course Evaluation etc.) are created and modified using the same views. These views exist in views/questionnaires folder. Hence the files to be modified to incorporate the new UI design will be:&lt;br /&gt;
&lt;br /&gt;
* view/questionnaires/new.html.erb&lt;br /&gt;
* view/questionnaires/edit.html.erb&lt;br /&gt;
* view/questionnaires/view.html.erb&lt;br /&gt;
&lt;br /&gt;
The modifications made to the above files will be significant since the new rubric creation interface will be entirely different form the existing one. A lot of the code will have to be written from scratch.&lt;br /&gt;
&lt;br /&gt;
== '''Testing Plan''' ==&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=105676</id>
		<title>CSC/ECE 517 Fall 2016/E1693. Drag-and-drop interface for creating rubrics</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=105676"/>
		<updated>2016-11-14T22:41:03Z</updated>

		<summary type="html">&lt;p&gt;Msardar: /* Design */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''Introduction to Expertiza''' ==&lt;br /&gt;
Expertiza is an online system that is used by students to view/submit assignments and review others' work. Expertiza also provides tools to visualize the scores and gauge the improvements made during the course semester. It also facilitates and monitors team projects. It is targeted at educational and non-profit organizations. &lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source project with the source code available as a public repository on GitHub. It is developed using Ruby on Rails and is increasingly becoming robust thanks to the innumerable bugs being fixed by the community. The project has a micro-blog on SourceForge where the developer community report bugs and document updates.&lt;br /&gt;
&lt;br /&gt;
=='''Problem Statement'''==&lt;br /&gt;
&lt;br /&gt;
The existing interface for defining rubric is not very user friendly. The instructors or TAs are required to define the type of the field, the dimension of the fields (length, height), and possibly the content of the widget e.g., available options for a combo box. Unfortunately, after they are done with the design phase, to see the final result of the rubric that is going to be presented to the students, they have to impersonate students, create a fake submissions, move the due dates etc. The existing rubrics creation page is shown in the Figure below.&lt;br /&gt;
&lt;br /&gt;
[[File:OldRubricPage.PNG|frame|upright|center|Old Rubric Creation Page]]&lt;br /&gt;
&lt;br /&gt;
We need to implement a WYSIWYG (What You See Is What You Get) UI for the rubric page to create rubrics which supports the following expertiza's question types:&lt;br /&gt;
&lt;br /&gt;
* Criterion&lt;br /&gt;
* Checkbox&lt;br /&gt;
* TextField&lt;br /&gt;
* Dropdown&lt;br /&gt;
* TextArea&lt;br /&gt;
* UploadFile&lt;br /&gt;
*  SectionHeader&lt;br /&gt;
* TableHeader&lt;br /&gt;
* ColumnHeader&lt;br /&gt;
* Scale&lt;br /&gt;
&lt;br /&gt;
== '''Design''' ==&lt;br /&gt;
To create the drag-and-drop interface, we can use the [https://formbuilder.online jQuery formBuilder plugin]. The jquery-rails gem is already present in the Gemfile, so we only need to initialize the formBuilder plugin.&lt;br /&gt;
&lt;br /&gt;
The advantages of using this plugin are:&lt;br /&gt;
&lt;br /&gt;
* 100% client-side plugin that gives users the power to create forms using an intuitive drag and drop interface.&lt;br /&gt;
* Customization - enable only the fields you need, use your own notifications append or prepend content and more.&lt;br /&gt;
* Bootstrap ready but not dependent&lt;br /&gt;
&lt;br /&gt;
A mockup for an example form is given below:&lt;br /&gt;
&lt;br /&gt;
[[File:JQuery.png|frame|upright|center|Sample Form using JQuery formBuilder]]&lt;br /&gt;
&lt;br /&gt;
The above screenshot consists of two sections: main area to the left and the control section to the right. The control section consists of the various form fields which can be dragged and dropped to the main area. In the main area, the parameters to the fields can be configured including field length, options, values, etc. Hence the drag and drop interface will provide a very intuitive way for the instructor/TA to create rubrics and also view how the page would appear to a student.&lt;br /&gt;
&lt;br /&gt;
== '''Files to be modified''' ==&lt;br /&gt;
This project only involves modifying the UI for instructors to create new rubrics. The rubric configurations stored in the database and the views from the student side will remain the same. Hence, no modifications need to be made to the questionnaire model or controller.&lt;br /&gt;
&lt;br /&gt;
All types of rubrics (Review, Metareview, Author Feedback, Teammate review, Survey, Course Evaluation etc.) are created and modified using the same views. These views exist in views/questionnaires folder. Hence the files to be modified to incorporate the new UI design will be:&lt;br /&gt;
&lt;br /&gt;
* view/questionnaires/new.html.erb&lt;br /&gt;
* view/questionnaires/edit.html.erb&lt;br /&gt;
* view/questionnaires/view.html.erb&lt;br /&gt;
&lt;br /&gt;
The modifications made to the above files will be significant since the new rubric creation interface will be entirely different form the existing one. A lot of the code will have to be written from scratch.&lt;br /&gt;
&lt;br /&gt;
== '''Testing Plan''' ==&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=105672</id>
		<title>CSC/ECE 517 Fall 2016/E1693. Drag-and-drop interface for creating rubrics</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=105672"/>
		<updated>2016-11-14T22:34:06Z</updated>

		<summary type="html">&lt;p&gt;Msardar: /* Problem Statement */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''Introduction to Expertiza''' ==&lt;br /&gt;
Expertiza is an online system that is used by students to view/submit assignments and review others' work. Expertiza also provides tools to visualize the scores and gauge the improvements made during the course semester. It also facilitates and monitors team projects. It is targeted at educational and non-profit organizations. &lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source project with the source code available as a public repository on GitHub. It is developed using Ruby on Rails and is increasingly becoming robust thanks to the innumerable bugs being fixed by the community. The project has a micro-blog on SourceForge where the developer community report bugs and document updates.&lt;br /&gt;
&lt;br /&gt;
=='''Problem Statement'''==&lt;br /&gt;
&lt;br /&gt;
The existing interface for defining rubric is not very user friendly. The instructors or TAs are required to define the type of the field, the dimension of the fields (length, height), and possibly the content of the widget e.g., available options for a combo box. Unfortunately, after they are done with the design phase, to see the final result of the rubric that is going to be presented to the students, they have to impersonate students, create a fake submissions, move the due dates etc. The existing rubrics creation page is shown in the Figure below.&lt;br /&gt;
&lt;br /&gt;
[[File:OldRubricPage.PNG|frame|upright|center|Old Rubric Creation Page]]&lt;br /&gt;
&lt;br /&gt;
We need to implement a WYSIWYG (What You See Is What You Get) UI for the rubric page to create rubrics which supports the following expertiza's question types:&lt;br /&gt;
&lt;br /&gt;
* Criterion&lt;br /&gt;
* Checkbox&lt;br /&gt;
* TextField&lt;br /&gt;
* Dropdown&lt;br /&gt;
* TextArea&lt;br /&gt;
* UploadFile&lt;br /&gt;
*  SectionHeader&lt;br /&gt;
* TableHeader&lt;br /&gt;
* ColumnHeader&lt;br /&gt;
* Scale&lt;br /&gt;
&lt;br /&gt;
== '''Design''' ==&lt;br /&gt;
To create the drag-and-drop interface, we can use the [https://formbuilder.online jQuery formBuilder plugin].&lt;br /&gt;
&lt;br /&gt;
The advantages of using this plugin are:&lt;br /&gt;
&lt;br /&gt;
* 100% client-side plugin that gives users the power to create forms using an intuitive drag and drop interface.&lt;br /&gt;
* Customization - enable only the fields you need, use your own notifications append or prepend content and more.&lt;br /&gt;
* Bootstrap ready but not dependent&lt;br /&gt;
&lt;br /&gt;
A mockup for an example form is given below:&lt;br /&gt;
&lt;br /&gt;
[[File:JQuery.png|frame|upright|center|Sample Form using JQuery formBuilder]]&lt;br /&gt;
&lt;br /&gt;
The above screenshot consists of two sections: main area to the left and the control section to the right. The control section consists of the various form fields which can be dragged and dropped to the main area. In the main area, the parameters to the fields can be configured including field length, options, values, etc. Hence the drag and drop interface will provide a very intuitive way for the instructor/TA to create rubrics and also view how the page would appear to a student.&lt;br /&gt;
&lt;br /&gt;
== '''Files to be modified''' ==&lt;br /&gt;
This project only involves modifying the UI for instructors to create new rubrics. The rubric configurations stored in the database and the views from the student side will remain the same. Hence, no modifications need to be made to the questionnaire model or controller.&lt;br /&gt;
&lt;br /&gt;
All types of rubrics (Review, Metareview, Author Feedback, Teammate review, Survey, Course Evaluation etc.) are created and modified using the same views. These views exist in views/questionnaires folder. Hence the files to be modified to incorporate the new UI design will be:&lt;br /&gt;
&lt;br /&gt;
* view/questionnaires/new.html.erb&lt;br /&gt;
* view/questionnaires/edit.html.erb&lt;br /&gt;
* view/questionnaires/view.html.erb&lt;br /&gt;
&lt;br /&gt;
The modifications made to the above files will be significant since the new rubric creation interface will be entirely different form the existing one. A lot of the code will have to be written from scratch.&lt;br /&gt;
&lt;br /&gt;
== '''Testing Plan''' ==&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=105671</id>
		<title>CSC/ECE 517 Fall 2016/E1693. Drag-and-drop interface for creating rubrics</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=105671"/>
		<updated>2016-11-14T22:33:21Z</updated>

		<summary type="html">&lt;p&gt;Msardar: /* Problem Statement */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''Introduction to Expertiza''' ==&lt;br /&gt;
Expertiza is an online system that is used by students to view/submit assignments and review others' work. Expertiza also provides tools to visualize the scores and gauge the improvements made during the course semester. It also facilitates and monitors team projects. It is targeted at educational and non-profit organizations. &lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source project with the source code available as a public repository on GitHub. It is developed using Ruby on Rails and is increasingly becoming robust thanks to the innumerable bugs being fixed by the community. The project has a micro-blog on SourceForge where the developer community report bugs and document updates.&lt;br /&gt;
&lt;br /&gt;
=='''Problem Statement'''==&lt;br /&gt;
&lt;br /&gt;
The existing interface for defining rubric is not very user friendly. The instructors or TAs are required to define the type of the field, the dimension of the fields (length, height), and possibly the content of the widget e.g., available options for a combo box. Unfortunately, after they are done with the design phase, to see the final result of the rubric that is going to be presented to the students, they have to impersonate students, create a fake submissions, move the due dates etc. The existing rubrics creation page is shown in the Figure below.&lt;br /&gt;
&lt;br /&gt;
[[File:OldRubricPage.PNG]]&lt;br /&gt;
&lt;br /&gt;
We need to implement a WYSIWYG (What You See Is What You Get) UI for the rubric page to create rubrics which supports the following expertiza's question types:&lt;br /&gt;
&lt;br /&gt;
* Criterion&lt;br /&gt;
* Checkbox&lt;br /&gt;
* TextField&lt;br /&gt;
* Dropdown&lt;br /&gt;
* TextArea&lt;br /&gt;
* UploadFile&lt;br /&gt;
*  SectionHeader&lt;br /&gt;
* TableHeader&lt;br /&gt;
* ColumnHeader&lt;br /&gt;
* Scale&lt;br /&gt;
&lt;br /&gt;
== '''Design''' ==&lt;br /&gt;
To create the drag-and-drop interface, we can use the [https://formbuilder.online jQuery formBuilder plugin].&lt;br /&gt;
&lt;br /&gt;
The advantages of using this plugin are:&lt;br /&gt;
&lt;br /&gt;
* 100% client-side plugin that gives users the power to create forms using an intuitive drag and drop interface.&lt;br /&gt;
* Customization - enable only the fields you need, use your own notifications append or prepend content and more.&lt;br /&gt;
* Bootstrap ready but not dependent&lt;br /&gt;
&lt;br /&gt;
A mockup for an example form is given below:&lt;br /&gt;
&lt;br /&gt;
[[File:JQuery.png|frame|upright|center|Sample Form using JQuery formBuilder]]&lt;br /&gt;
&lt;br /&gt;
The above screenshot consists of two sections: main area to the left and the control section to the right. The control section consists of the various form fields which can be dragged and dropped to the main area. In the main area, the parameters to the fields can be configured including field length, options, values, etc. Hence the drag and drop interface will provide a very intuitive way for the instructor/TA to create rubrics and also view how the page would appear to a student.&lt;br /&gt;
&lt;br /&gt;
== '''Files to be modified''' ==&lt;br /&gt;
This project only involves modifying the UI for instructors to create new rubrics. The rubric configurations stored in the database and the views from the student side will remain the same. Hence, no modifications need to be made to the questionnaire model or controller.&lt;br /&gt;
&lt;br /&gt;
All types of rubrics (Review, Metareview, Author Feedback, Teammate review, Survey, Course Evaluation etc.) are created and modified using the same views. These views exist in views/questionnaires folder. Hence the files to be modified to incorporate the new UI design will be:&lt;br /&gt;
&lt;br /&gt;
* view/questionnaires/new.html.erb&lt;br /&gt;
* view/questionnaires/edit.html.erb&lt;br /&gt;
* view/questionnaires/view.html.erb&lt;br /&gt;
&lt;br /&gt;
The modifications made to the above files will be significant since the new rubric creation interface will be entirely different form the existing one. A lot of the code will have to be written from scratch.&lt;br /&gt;
&lt;br /&gt;
== '''Testing Plan''' ==&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=105670</id>
		<title>CSC/ECE 517 Fall 2016/E1693. Drag-and-drop interface for creating rubrics</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=105670"/>
		<updated>2016-11-14T22:32:31Z</updated>

		<summary type="html">&lt;p&gt;Msardar: /* Problem Statement */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''Introduction to Expertiza''' ==&lt;br /&gt;
Expertiza is an online system that is used by students to view/submit assignments and review others' work. Expertiza also provides tools to visualize the scores and gauge the improvements made during the course semester. It also facilitates and monitors team projects. It is targeted at educational and non-profit organizations. &lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source project with the source code available as a public repository on GitHub. It is developed using Ruby on Rails and is increasingly becoming robust thanks to the innumerable bugs being fixed by the community. The project has a micro-blog on SourceForge where the developer community report bugs and document updates.&lt;br /&gt;
&lt;br /&gt;
=='''Problem Statement'''==&lt;br /&gt;
&lt;br /&gt;
The existing interface for defining rubric is not very user friendly. The instructors or TAs are required to define the type of the field, the dimension of the fields (length, height), and possibly the content of the widget e.g., available options for a combo box. Unfortunately, after they are done with the design phase, to see the final result of the rubric that is going to be presented to the students, they have to impersonate students, create a fake submissions, move the due dates etc. The existing rubrics creation page is shown in the Figure below.&lt;br /&gt;
&lt;br /&gt;
[[File:OldRubricPage.png|frame|upright|center|Old Rubric Page]]&lt;br /&gt;
&lt;br /&gt;
We need to implement a WYSIWYG (What You See Is What You Get) UI for the rubric page to create rubrics which supports the following expertiza's question types:&lt;br /&gt;
&lt;br /&gt;
* Criterion&lt;br /&gt;
* Checkbox&lt;br /&gt;
* TextField&lt;br /&gt;
* Dropdown&lt;br /&gt;
* TextArea&lt;br /&gt;
* UploadFile&lt;br /&gt;
*  SectionHeader&lt;br /&gt;
* TableHeader&lt;br /&gt;
* ColumnHeader&lt;br /&gt;
* Scale&lt;br /&gt;
&lt;br /&gt;
== '''Design''' ==&lt;br /&gt;
To create the drag-and-drop interface, we can use the [https://formbuilder.online jQuery formBuilder plugin].&lt;br /&gt;
&lt;br /&gt;
The advantages of using this plugin are:&lt;br /&gt;
&lt;br /&gt;
* 100% client-side plugin that gives users the power to create forms using an intuitive drag and drop interface.&lt;br /&gt;
* Customization - enable only the fields you need, use your own notifications append or prepend content and more.&lt;br /&gt;
* Bootstrap ready but not dependent&lt;br /&gt;
&lt;br /&gt;
A mockup for an example form is given below:&lt;br /&gt;
&lt;br /&gt;
[[File:JQuery.png|frame|upright|center|Sample Form using JQuery formBuilder]]&lt;br /&gt;
&lt;br /&gt;
The above screenshot consists of two sections: main area to the left and the control section to the right. The control section consists of the various form fields which can be dragged and dropped to the main area. In the main area, the parameters to the fields can be configured including field length, options, values, etc. Hence the drag and drop interface will provide a very intuitive way for the instructor/TA to create rubrics and also view how the page would appear to a student.&lt;br /&gt;
&lt;br /&gt;
== '''Files to be modified''' ==&lt;br /&gt;
This project only involves modifying the UI for instructors to create new rubrics. The rubric configurations stored in the database and the views from the student side will remain the same. Hence, no modifications need to be made to the questionnaire model or controller.&lt;br /&gt;
&lt;br /&gt;
All types of rubrics (Review, Metareview, Author Feedback, Teammate review, Survey, Course Evaluation etc.) are created and modified using the same views. These views exist in views/questionnaires folder. Hence the files to be modified to incorporate the new UI design will be:&lt;br /&gt;
&lt;br /&gt;
* view/questionnaires/new.html.erb&lt;br /&gt;
* view/questionnaires/edit.html.erb&lt;br /&gt;
* view/questionnaires/view.html.erb&lt;br /&gt;
&lt;br /&gt;
The modifications made to the above files will be significant since the new rubric creation interface will be entirely different form the existing one. A lot of the code will have to be written from scratch.&lt;br /&gt;
&lt;br /&gt;
== '''Testing Plan''' ==&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=105669</id>
		<title>CSC/ECE 517 Fall 2016/E1693. Drag-and-drop interface for creating rubrics</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=105669"/>
		<updated>2016-11-14T22:31:12Z</updated>

		<summary type="html">&lt;p&gt;Msardar: /* Problem Statement */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''Introduction to Expertiza''' ==&lt;br /&gt;
Expertiza is an online system that is used by students to view/submit assignments and review others' work. Expertiza also provides tools to visualize the scores and gauge the improvements made during the course semester. It also facilitates and monitors team projects. It is targeted at educational and non-profit organizations. &lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source project with the source code available as a public repository on GitHub. It is developed using Ruby on Rails and is increasingly becoming robust thanks to the innumerable bugs being fixed by the community. The project has a micro-blog on SourceForge where the developer community report bugs and document updates.&lt;br /&gt;
&lt;br /&gt;
=='''Problem Statement'''==&lt;br /&gt;
&lt;br /&gt;
The existing interface for defining rubric is not very user friendly. The instructors or TAs are required to define the type of the field, the dimension of the fields (length, height), and possibly the content of the widget e.g., available options for a combo box. Unfortunately, after they are done with the design phase, to see the final result of the rubric that is going to be presented to the students, they have to impersonate students, create a fake submissions, move the due dates etc. The existing rubrics creation page is shown in the Figure below.&lt;br /&gt;
&lt;br /&gt;
[[File:OldRubricPage.png]]&lt;br /&gt;
&lt;br /&gt;
We need to implement a WYSIWYG (What You See Is What You Get) UI for the rubric page to create rubrics which supports the following expertiza's question types:&lt;br /&gt;
&lt;br /&gt;
* Criterion&lt;br /&gt;
* Checkbox&lt;br /&gt;
* TextField&lt;br /&gt;
* Dropdown&lt;br /&gt;
* TextArea&lt;br /&gt;
* UploadFile&lt;br /&gt;
*  SectionHeader&lt;br /&gt;
* TableHeader&lt;br /&gt;
* ColumnHeader&lt;br /&gt;
* Scale&lt;br /&gt;
&lt;br /&gt;
== '''Design''' ==&lt;br /&gt;
To create the drag-and-drop interface, we can use the [https://formbuilder.online jQuery formBuilder plugin].&lt;br /&gt;
&lt;br /&gt;
The advantages of using this plugin are:&lt;br /&gt;
&lt;br /&gt;
* 100% client-side plugin that gives users the power to create forms using an intuitive drag and drop interface.&lt;br /&gt;
* Customization - enable only the fields you need, use your own notifications append or prepend content and more.&lt;br /&gt;
* Bootstrap ready but not dependent&lt;br /&gt;
&lt;br /&gt;
A mockup for an example form is given below:&lt;br /&gt;
&lt;br /&gt;
[[File:JQuery.png|frame|upright|center|Sample Form using JQuery formBuilder]]&lt;br /&gt;
&lt;br /&gt;
The above screenshot consists of two sections: main area to the left and the control section to the right. The control section consists of the various form fields which can be dragged and dropped to the main area. In the main area, the parameters to the fields can be configured including field length, options, values, etc. Hence the drag and drop interface will provide a very intuitive way for the instructor/TA to create rubrics and also view how the page would appear to a student.&lt;br /&gt;
&lt;br /&gt;
== '''Files to be modified''' ==&lt;br /&gt;
This project only involves modifying the UI for instructors to create new rubrics. The rubric configurations stored in the database and the views from the student side will remain the same. Hence, no modifications need to be made to the questionnaire model or controller.&lt;br /&gt;
&lt;br /&gt;
All types of rubrics (Review, Metareview, Author Feedback, Teammate review, Survey, Course Evaluation etc.) are created and modified using the same views. These views exist in views/questionnaires folder. Hence the files to be modified to incorporate the new UI design will be:&lt;br /&gt;
&lt;br /&gt;
* view/questionnaires/new.html.erb&lt;br /&gt;
* view/questionnaires/edit.html.erb&lt;br /&gt;
* view/questionnaires/view.html.erb&lt;br /&gt;
&lt;br /&gt;
The modifications made to the above files will be significant since the new rubric creation interface will be entirely different form the existing one. A lot of the code will have to be written from scratch.&lt;br /&gt;
&lt;br /&gt;
== '''Testing Plan''' ==&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:OldRubricPage.PNG&amp;diff=105668</id>
		<title>File:OldRubricPage.PNG</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:OldRubricPage.PNG&amp;diff=105668"/>
		<updated>2016-11-14T22:30:35Z</updated>

		<summary type="html">&lt;p&gt;Msardar: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=105629</id>
		<title>CSC/ECE 517 Fall 2016/E1693. Drag-and-drop interface for creating rubrics</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=105629"/>
		<updated>2016-11-14T21:55:04Z</updated>

		<summary type="html">&lt;p&gt;Msardar: /* Files to be modified */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''Introduction to Expertiza''' ==&lt;br /&gt;
Expertiza is an online system that is used by students to view/submit assignments and review others' work. Expertiza also provides tools to visualize the scores and gauge the improvements made during the course semester. It also facilitates and monitors team projects. It is targeted at educational and non-profit organizations. &lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source project with the source code available as a public repository on GitHub. It is developed using Ruby on Rails and is increasingly becoming robust thanks to the innumerable bugs being fixed by the community. The project has a micro-blog on SourceForge where the developer community report bugs and document updates.&lt;br /&gt;
&lt;br /&gt;
=='''Problem Statement'''==&lt;br /&gt;
&lt;br /&gt;
The existing interface for defining rubric is not very user friendly. The instructors or TAs are required to define the type of the field, the dimension of the fields (length, height), and possibly the content of the widget e.g., available options for a combo box. Unfortunately, after they are done with the design phase, to see the final result of the rubric that is going to be presented to the students, they have to impersonate students, create a fake submissions, move the due dates etc. &lt;br /&gt;
&lt;br /&gt;
We need to implement a WYSIWYG (What You See Is What You Get) UI for the rubric page to create rubrics which supports the following expertiza's question types:&lt;br /&gt;
&lt;br /&gt;
* Criterion&lt;br /&gt;
* Checkbox&lt;br /&gt;
* TextField&lt;br /&gt;
* Dropdown&lt;br /&gt;
* TextArea&lt;br /&gt;
* UploadFile&lt;br /&gt;
*  SectionHeader&lt;br /&gt;
* TableHeader&lt;br /&gt;
* ColumnHeader&lt;br /&gt;
* Scale&lt;br /&gt;
&lt;br /&gt;
== '''Design''' ==&lt;br /&gt;
To create the drag-and-drop interface, we can use the [https://formbuilder.online jQuery formBuilder plugin].&lt;br /&gt;
&lt;br /&gt;
The advantages of using this plugin are:&lt;br /&gt;
&lt;br /&gt;
* 100% client-side plugin that gives users the power to create forms using an intuitive drag and drop interface.&lt;br /&gt;
* Customization - enable only the fields you need, use your own notifications append or prepend content and more.&lt;br /&gt;
* Bootstrap ready but not dependent&lt;br /&gt;
&lt;br /&gt;
A mockup for an example form is given below:&lt;br /&gt;
&lt;br /&gt;
[[File:JQuery.png|frame|upright|center|Sample Form using JQuery formBuilder]]&lt;br /&gt;
&lt;br /&gt;
The above screenshot consists of two sections: main area to the left and the control section to the right. The control section consists of the various form fields which can be dragged and dropped to the main area. In the main area, the parameters to the fields can be configured including field length, options, values, etc. Hence the drag and drop interface will provide a very intuitive way for the instructor/TA to create rubrics and also view how the page would appear to a student.&lt;br /&gt;
&lt;br /&gt;
== '''Files to be modified''' ==&lt;br /&gt;
This project only involves modifying the UI for instructors to create new rubrics. The rubric configurations stored in the database and the views from the student side will remain the same. Hence, no modifications need to be made to the questionnaire model or controller.&lt;br /&gt;
&lt;br /&gt;
All types of rubrics (Review, Metareview, Author Feedback, Teammate review, Survey, Course Evaluation etc.) are created and modified using the same views. These views exist in views/questionnaires folder. Hence the files to be modified to incorporate the new UI design will be:&lt;br /&gt;
&lt;br /&gt;
* view/questionnaires/new.html.erb&lt;br /&gt;
* view/questionnaires/edit.html.erb&lt;br /&gt;
* view/questionnaires/view.html.erb&lt;br /&gt;
&lt;br /&gt;
The modifications made to the above files will be significant since the new rubric creation interface will be entirely different form the existing one. A lot of the code will have to be written from scratch.&lt;br /&gt;
&lt;br /&gt;
== '''Testing Plan''' ==&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=105627</id>
		<title>CSC/ECE 517 Fall 2016/E1693. Drag-and-drop interface for creating rubrics</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=105627"/>
		<updated>2016-11-14T21:48:12Z</updated>

		<summary type="html">&lt;p&gt;Msardar: files to be modified&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== '''Introduction to Expertiza''' ==&lt;br /&gt;
Expertiza is an online system that is used by students to view/submit assignments and review others' work. Expertiza also provides tools to visualize the scores and gauge the improvements made during the course semester. It also facilitates and monitors team projects. It is targeted at educational and non-profit organizations. &lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source project with the source code available as a public repository on GitHub. It is developed using Ruby on Rails and is increasingly becoming robust thanks to the innumerable bugs being fixed by the community. The project has a micro-blog on SourceForge where the developer community report bugs and document updates.&lt;br /&gt;
&lt;br /&gt;
=='''Problem Statement'''==&lt;br /&gt;
&lt;br /&gt;
The existing interface for defining rubric is not very user friendly. The instructors or TAs are required to define the type of the field, the dimension of the fields (length, height), and possibly the content of the widget e.g., available options for a combo box. Unfortunately, after they are done with the design phase, to see the final result of the rubric that is going to be presented to the students, they have to impersonate students, create a fake submissions, move the due dates etc. &lt;br /&gt;
&lt;br /&gt;
We need to implement a WYSIWYG (What You See Is What You Get) UI for the rubric page to create rubrics which supports the following expertiza's question types:&lt;br /&gt;
&lt;br /&gt;
* Criterion&lt;br /&gt;
* Checkbox&lt;br /&gt;
* TextField&lt;br /&gt;
* Dropdown&lt;br /&gt;
* TextArea&lt;br /&gt;
* UploadFile&lt;br /&gt;
*  SectionHeader&lt;br /&gt;
* TableHeader&lt;br /&gt;
* ColumnHeader&lt;br /&gt;
* Scale&lt;br /&gt;
&lt;br /&gt;
== '''Design''' ==&lt;br /&gt;
To create the drag-and-drop interface, we can use the [https://formbuilder.online jQuery formBuilder plugin].&lt;br /&gt;
&lt;br /&gt;
The advantages of using this plugin are:&lt;br /&gt;
&lt;br /&gt;
* 100% client-side plugin that gives users the power to create forms using an intuitive drag and drop interface.&lt;br /&gt;
* Customization - enable only the fields you need, use your own notifications append or prepend content and more.&lt;br /&gt;
* Bootstrap ready but not dependent&lt;br /&gt;
&lt;br /&gt;
A mockup for an example form is given below:&lt;br /&gt;
&lt;br /&gt;
[[File:JQuery.png|frame|upright|center|Sample Form using JQuery formBuilder]]&lt;br /&gt;
&lt;br /&gt;
The above screenshot consists of two sections: main area to the left and the control section to the right. The control section consists of the various form fields which can be dragged and dropped to the main area. In the main area, the parameters to the fields can be configured including field length, options, values, etc. Hence the drag and drop interface will provide a very intuitive way for the instructor/TA to create rubrics and also view how the page would appear to a student.&lt;br /&gt;
&lt;br /&gt;
== '''Files to be modified''' ==&lt;br /&gt;
All types of rubrics (Review, Metareview, Author Feedback, Teammate review, Survey, Course Evaluation etc.) are created and modified using the same views. These views exist in views/questionnaires folders. Hence the files to be modified to incorporate the new UI design will be:&lt;br /&gt;
&lt;br /&gt;
* view/questionnaires/new.html.erb&lt;br /&gt;
* view/questionnaires/edit.html.erb&lt;br /&gt;
* view/questionnaires/view.html.erb&lt;br /&gt;
&lt;br /&gt;
The modifications made to the above files will be significant since the new rubric creation interface will be entirely different form the existing one. A lot of the code will have to be written from scratch.&lt;br /&gt;
&lt;br /&gt;
This project only involves modifying the UI for instructors to create new rubrics. The rubric configurations stored in the database and the views from the student side will remain the same. &lt;br /&gt;
&lt;br /&gt;
== '''Testing Plan''' ==&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=104744</id>
		<title>CSC/ECE 517 Fall 2016/E1693. Drag-and-drop interface for creating rubrics</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=104744"/>
		<updated>2016-11-08T21:29:31Z</updated>

		<summary type="html">&lt;p&gt;Msardar: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Introduction to Expertiza ==&lt;br /&gt;
Expertiza is an online system that is used by students to view/submit assignments and review others' work. Expertiza also provides tools to visualize the scores and gauge the improvements made during the course semester. It also facilitates and monitors team projects. It is targeted at educational and non-profit organizations. &lt;br /&gt;
&lt;br /&gt;
Expertiza is an open-source project with the source code available as a public repository on GitHub. It is developed using Ruby on Rails and is increasingly becoming robust thanks to the innumerable bugs being fixed by the community. The project has a micro-blog on SourceForge where the developer community report bugs and document updates.&lt;br /&gt;
&lt;br /&gt;
=='''Problem Statement'''==&lt;br /&gt;
&lt;br /&gt;
The existing interface for defining rubric is not very user friendly. The instructors or TAs are required to define the type of the field, the dimension of the fields (length, height), and possibly the content of the widget e.g., available options for a combo box. Unfortunately, after they are done with the design phase, to see the final result of the rubric that is going to be presented to the students, they have to impersonate students, create a fake submissions, move the due dates etc.&lt;br /&gt;
&lt;br /&gt;
== '''Design''' ==&lt;br /&gt;
To create the drag-and-drop interface, we can use the [https://formbuilder.online jQuery formBuilder plugin].&lt;br /&gt;
&lt;br /&gt;
The advantages of using this plugin are:&lt;br /&gt;
&lt;br /&gt;
* 100% client-side plugin that gives users the power to create forms using an intuitive drag and drop interface.&lt;br /&gt;
* Customization - enable only the fields you need, use your own notifications append or prepend content and more.&lt;br /&gt;
* Bootstrap ready but not dependent&lt;br /&gt;
&lt;br /&gt;
A mockup for an example form is given below:&lt;br /&gt;
&lt;br /&gt;
[[File:JQuery.png|frame|upright|center|Sample Form using JQuery formBuilder]]&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=104738</id>
		<title>CSC/ECE 517 Fall 2016/E1693. Drag-and-drop interface for creating rubrics</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=104738"/>
		<updated>2016-11-08T21:12:54Z</updated>

		<summary type="html">&lt;p&gt;Msardar: /* Design */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=='''Introduction to Expertiza'''==&lt;br /&gt;
Expertiza is an online system that is used by students to view/submit assignments and review others' work. Expertiza also provides tools to visualize the scores and gauge the improvements made during the course semester. It also facilitates and monitors team projects. It is targeted at educational and non-profit organizations. The project is funded by the National Software Foundation (NSF), NCSU Learning in a Technology-Rich Environment (LITRE) program, the NCSU Faculty Center for Teaching and Learning, the NCSU STEM Initiative, and the Center for Advanced Computing and Communication.&lt;br /&gt;
Expertiza is an open-source project with the source code available as a public repository on GitHub. It is developed using Ruby on Rails and is increasingly becoming robust thanks to the innumerable bugs being fixed by the community. The project has a micro-blog on SourceForge where the developer community report bugs and document updates.&lt;br /&gt;
&lt;br /&gt;
=='''Problem Statement'''==&lt;br /&gt;
&lt;br /&gt;
The existing interface for defining rubric is not very user friendly. The instructors or TAs are required to define the type of the field, the dimension of the fields (length, height), and possibly the content of the widget e.g., available options for a combo box. Unfortunately, after they are done with the design phase, to see the final result of the rubric that is going to be presented to the students, they have to impersonate students, create a fake submissions, move the due dates etc.&lt;br /&gt;
&lt;br /&gt;
== '''Design''' ==&lt;br /&gt;
To create the drag-and-drop interface, we can use the [https://formbuilder.online jQuery formBuilder plugin].&lt;br /&gt;
The advantages of using this plugin are:&lt;br /&gt;
&lt;br /&gt;
* 100% client-side plugin that gives users the power to create forms using an intuitive drag and drop interface.&lt;br /&gt;
* Customization - enable only the fields you need, use your own notifications append or prepend content and more.&lt;br /&gt;
* Bootstrap ready but not dependent&lt;br /&gt;
&lt;br /&gt;
A mockup for an example form is given below:&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=104737</id>
		<title>CSC/ECE 517 Fall 2016/E1693. Drag-and-drop interface for creating rubrics</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=104737"/>
		<updated>2016-11-08T21:11:46Z</updated>

		<summary type="html">&lt;p&gt;Msardar: /* Design */ advantages&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=='''Introduction to Expertiza'''==&lt;br /&gt;
Expertiza is an online system that is used by students to view/submit assignments and review others' work. Expertiza also provides tools to visualize the scores and gauge the improvements made during the course semester. It also facilitates and monitors team projects. It is targeted at educational and non-profit organizations. The project is funded by the National Software Foundation (NSF), NCSU Learning in a Technology-Rich Environment (LITRE) program, the NCSU Faculty Center for Teaching and Learning, the NCSU STEM Initiative, and the Center for Advanced Computing and Communication.&lt;br /&gt;
Expertiza is an open-source project with the source code available as a public repository on GitHub. It is developed using Ruby on Rails and is increasingly becoming robust thanks to the innumerable bugs being fixed by the community. The project has a micro-blog on SourceForge where the developer community report bugs and document updates.&lt;br /&gt;
&lt;br /&gt;
=='''Problem Statement'''==&lt;br /&gt;
&lt;br /&gt;
The existing interface for defining rubric is not very user friendly. The instructors or TAs are required to define the type of the field, the dimension of the fields (length, height), and possibly the content of the widget e.g., available options for a combo box. Unfortunately, after they are done with the design phase, to see the final result of the rubric that is going to be presented to the students, they have to impersonate students, create a fake submissions, move the due dates etc.&lt;br /&gt;
&lt;br /&gt;
== '''Design''' ==&lt;br /&gt;
To create the drag-and-drop interface, we can use the [https://formbuilder.online jQuery formBuilder plugin].&lt;br /&gt;
The advantages of using this plugin are:&lt;br /&gt;
&lt;br /&gt;
1) 100% client-side plugin that gives users the power to create forms using an intuitive drag and drop interface.&lt;br /&gt;
2) Customization - enable only the fields you need, use your own notifications append or prepend content and more.&lt;br /&gt;
3) Bootstrap ready but not dependent&lt;br /&gt;
&lt;br /&gt;
A mockup for an example form is given below:&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=104736</id>
		<title>CSC/ECE 517 Fall 2016/E1693. Drag-and-drop interface for creating rubrics</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1693._Drag-and-drop_interface_for_creating_rubrics&amp;diff=104736"/>
		<updated>2016-11-08T21:06:56Z</updated>

		<summary type="html">&lt;p&gt;Msardar: /* Design */ jQuery link&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=='''Introduction to Expertiza'''==&lt;br /&gt;
Expertiza is an online system that is used by students to view/submit assignments and review others' work. Expertiza also provides tools to visualize the scores and gauge the improvements made during the course semester. It also facilitates and monitors team projects. It is targeted at educational and non-profit organizations. The project is funded by the National Software Foundation (NSF), NCSU Learning in a Technology-Rich Environment (LITRE) program, the NCSU Faculty Center for Teaching and Learning, the NCSU STEM Initiative, and the Center for Advanced Computing and Communication.&lt;br /&gt;
Expertiza is an open-source project with the source code available as a public repository on GitHub. It is developed using Ruby on Rails and is increasingly becoming robust thanks to the innumerable bugs being fixed by the community. The project has a micro-blog on SourceForge where the developer community report bugs and document updates.&lt;br /&gt;
&lt;br /&gt;
=='''Problem Statement'''==&lt;br /&gt;
&lt;br /&gt;
The existing interface for defining rubric is not very user friendly. The instructors or TAs are required to define the type of the field, the dimension of the fields (length, height), and possibly the content of the widget e.g., available options for a combo box. Unfortunately, after they are done with the design phase, to see the final result of the rubric that is going to be presented to the students, they have to impersonate students, create a fake submissions, move the due dates etc.&lt;br /&gt;
&lt;br /&gt;
== '''Design''' ==&lt;br /&gt;
To create the drag-and-drop interface, we can use the [https://formbuilder.online jQuery formBuilder plugin]&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1644._Refactor_and_test_Teams_Controller&amp;diff=103840</id>
		<title>CSC/ECE 517 Fall 2016/E1644. Refactor and test Teams Controller</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1644._Refactor_and_test_Teams_Controller&amp;diff=103840"/>
		<updated>2016-10-29T03:56:02Z</updated>

		<summary type="html">&lt;p&gt;Msardar: /* Changes to GUI */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;'''E1644: Refactor and Test 'Teams_Controller' Controller'''&amp;lt;ref&amp;gt;Project Description document https://google.com&amp;lt;/ref&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This page provides a brief description of the '''Expertiza''' project. The project is aimed at refactoring and testing the 'Teams_Controller' Controller, which contains the methods to create new teams, list the existing teams, create new teams by inheriting existing teams, deleting existing teams and creating multiple teams at once by assigning them random topics. The project entailed, refactoring some part of the controller to improve the readability of code and then creating test cases in [https://en.wikipedia.org/wiki/RSpec RSpec] to verify the methods it possesses. &lt;br /&gt;
&lt;br /&gt;
==Introduction to Expertiza==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a peer review based system which provides incremental learning from the class. This project has been developed together by faculty and students using [http://rubyonrails.org/ Ruby on Rails] framework. Expertiza allows the instructor to create, edit and delete assignments, create new assignment topics, assign them to a particular class or selected students, have students work on teams and then review each other's assignments at the end. For the students, they can signup for topics, form teams, and submit their projects and assignments. &lt;br /&gt;
Students then review the work done by other students and give suggestions to improve. Teams after reviews are allotted scores and they can refer to the peer comments to further improve their work. It also supports submission of different file types for assignments, including the URLs and wiki pages.&lt;br /&gt;
&lt;br /&gt;
== Project Description ==&lt;br /&gt;
'''Teams_Controller''' primarily handles the team creation, deletion and other behaviours. Most of those are called from the instructor’s view. When manual testing is done, most of the methods can be called by clicking the “Create teams” icon from both assignments and courses. &lt;br /&gt;
The following tasks have been performed as per the requirements.&lt;br /&gt;
&lt;br /&gt;
As a part of the project, some GUI's changes had to be made because they did not work the way they should have, some minor issues in the code were fixed and tests were written in '''RSpec''' for the methods delete, create, create teams, list and inherit.&lt;br /&gt;
&lt;br /&gt;
===Create Method===&lt;br /&gt;
The method '''Create''' is called when an instructor tries to create a team manually. This works for both, creating ''assignment teams'' and ''course teams''. Assignment teams are teams made to do a particular assignment together and ''Course Teams'' are teams which are made for the whole course.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to create course teams.&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to create assignment teams.&lt;br /&gt;
&lt;br /&gt;
===Delete Method===&lt;br /&gt;
The method '''Delete''' is called when an instructor tries to delete a team manually. This works for both, deleting ''assignment teams'' and ''course teams''.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to delete course teams.&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to delete assignment teams.&lt;br /&gt;
&lt;br /&gt;
===List Method===&lt;br /&gt;
The method '''List''' lists all the team nodes and the instructor is able to expand each team node to see the user nodes as well.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To check that all teams are being listed in the view.&lt;br /&gt;
&lt;br /&gt;
===Inherit Method===&lt;br /&gt;
The method '''Inherit''' inherits teams from course to assignments, but the “Inherit Teams From Course” option should not display when either 1) we are editing a course object or 2) the current assignment object does not have a course associated with it.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is displayed while creating an assignment team.&lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is not displayed while creating a course team. &lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is not displayed while creating teams for an assignment without a course.&lt;br /&gt;
&lt;br /&gt;
== Refactoring ==&lt;br /&gt;
'''Refactoring'''&amp;lt;ref&amp;gt;Refactoring https://en.wikipedia.org/wiki/Code_refactoring&amp;lt;/ref&amp;gt; is restructuring of code without the need of changing any external behavior. It reduces complexity and improves readability. It also becomes easy to extend the application with respect to different modules and their functionalities.&lt;br /&gt;
Some common techniques to refactor are:&lt;br /&gt;
&lt;br /&gt;
* Moving methods to appropriate modules&lt;br /&gt;
* Breaking methods into more meaningful functionality&lt;br /&gt;
* Creating more generalized code.&lt;br /&gt;
* Renaming methods and variable.&lt;br /&gt;
* Inheritance&lt;br /&gt;
&lt;br /&gt;
As the part of the project, the variable ''@signUps'' in the delete method in the teams_controller was changed to snake case, tp improve readability of code.&lt;br /&gt;
&lt;br /&gt;
== Changes to View == &lt;br /&gt;
To fix the view for ''inherit teams'' functionality, changes to the view were made.&lt;br /&gt;
&lt;br /&gt;
Initially, the code was:&lt;br /&gt;
&lt;br /&gt;
  Inherit Teams From Course&lt;br /&gt;
  Use the teams that are currently defined for the course.&lt;br /&gt;
 &amp;lt;%= form_tag :action =&amp;gt; 'inherit' do %&amp;gt;&lt;br /&gt;
   &amp;lt;%= hidden_field_tag 'id', @parent.id %&amp;gt;&lt;br /&gt;
   &amp;lt;%= submit_tag &amp;quot;Inherit&amp;quot; %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Which was changed to:&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;% if not @parent.instance_of?(Course) and not @parent.course.nil? %&amp;gt;&lt;br /&gt;
    Inherit Teams From Course &lt;br /&gt;
    Use the teams that are currently defined for the course.&lt;br /&gt;
   &amp;lt;%= form_tag :action =&amp;gt; 'inherit' do %&amp;gt;&lt;br /&gt;
     &amp;lt;%= hidden_field_tag 'id', @parent.id %&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
    &amp;lt;%= submit_tag &amp;quot;Inherit&amp;quot; %&amp;gt;&lt;br /&gt;
  &amp;lt;% end %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To fix the view, in the ''new.html.erb'' file of teams, we enclose the inherit teams section in an ''if condition'' that checks that the parent of the team is not a Course and it is not an Assignment whose course is nil.&lt;br /&gt;
&lt;br /&gt;
== Testing the Teams_Controller ==&lt;br /&gt;
&lt;br /&gt;
===Testing Inherit Method===&lt;br /&gt;
&lt;br /&gt;
To test that while creating an assignment team, the inherit teams section should be displayed, we login as instructor got to list page and click on Create Team Link. On this page we test that it should contain the string 'Inherit Teams From Course'.&lt;br /&gt;
&lt;br /&gt;
  it 'should display inherit teams while creating an assignment team' do&lt;br /&gt;
    create(:assignment)&lt;br /&gt;
    create(:assignment_node)&lt;br /&gt;
    create(:assignment_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)&lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Assignment'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
To test that while creating a course team, the inherit teams section should not be displayed, we do same steps as previous case but finally we test that the page does NOT contain 'Inherit Teams from Course'&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  it 'should not display inherit teams while creating a course team' do&lt;br /&gt;
    create(:course)&lt;br /&gt;
    create(:course_node)&lt;br /&gt;
    create(:course_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)&lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Course'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_no_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
Similiarly, for creating a team for an assignment without a course, we test that the page does not contain 'Inherit Teams From Course'. For this particular test case, we added a new factory object for that defined an assignment with course set to nil.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  it 'should not display inherit teams while creating team for an assignment without a course' do&lt;br /&gt;
    create(:assignment_without_course)&lt;br /&gt;
    create(:assignment_without_course_node)&lt;br /&gt;
    create(:assignment_without_course_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)    &lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Assignment'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_no_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
===Testing Create Method===&lt;br /&gt;
&lt;br /&gt;
This test checks that after creating an assignment team the count in the teams table increase by 1.&lt;br /&gt;
&lt;br /&gt;
    describe &amp;quot;POST #create&amp;quot; do&lt;br /&gt;
    context &amp;quot;with an assignment team&amp;quot; do&lt;br /&gt;
      it &amp;quot;increases count by 1&amp;quot; do	&lt;br /&gt;
        expect{create :assignment_team, assignment: @assignment}.to change(Team,:count).by(1)&lt;br /&gt;
      end&lt;br /&gt;
     it &amp;quot;redirects to the list page&amp;quot; do&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
   end&lt;br /&gt;
&lt;br /&gt;
The same test for a course team as well&lt;br /&gt;
&lt;br /&gt;
    context &amp;quot;with a course team&amp;quot; do&lt;br /&gt;
      it &amp;quot;increases the count by 1&amp;quot; do&lt;br /&gt;
        expect{create :course_team, course: @course}.to change(Team,:count).by(1)&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
===Testing Delete Method===&lt;br /&gt;
    &lt;br /&gt;
&lt;br /&gt;
   context &amp;quot;with an assignment team &amp;quot; do&lt;br /&gt;
      it &amp;quot;deletes an assignment team&amp;quot; do&lt;br /&gt;
        @assignment = create(:assignment)&lt;br /&gt;
        @a_team = create(:assignment_team)&lt;br /&gt;
        expect{ @a_team.delete }.to change(Team, :count).by(-1)&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
    &lt;br /&gt;
    context &amp;quot;with a course team &amp;quot; do&lt;br /&gt;
      it &amp;quot;deletes a course team&amp;quot; do&lt;br /&gt;
        @course = create(:course)&lt;br /&gt;
        @c_team = create(:course_team)&lt;br /&gt;
        expect{ @c_team.delete }.to change(Team, :count).by(-1)&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
===Testing List Method===&lt;br /&gt;
&lt;br /&gt;
 describe 'List Team' do&lt;br /&gt;
 &lt;br /&gt;
   it 'should list all team nodes' do&lt;br /&gt;
     create(:assignment)&lt;br /&gt;
     create(:assignment_node)&lt;br /&gt;
     assignment_team = create(:assignment_team)&lt;br /&gt;
    team_user = create(:team_user)&lt;br /&gt;
     login_as(&amp;quot;instructor6&amp;quot;)&lt;br /&gt;
     visit '/teams/list?id=1&amp;amp;type=Assignment'&lt;br /&gt;
     page.all('#theTable tr').each do |tr|&lt;br /&gt;
       expect(tr).to have_content?(assignment_team.name)&lt;br /&gt;
     end&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
==References==&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1644._Refactor_and_test_Teams_Controller&amp;diff=103837</id>
		<title>CSC/ECE 517 Fall 2016/E1644. Refactor and test Teams Controller</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1644._Refactor_and_test_Teams_Controller&amp;diff=103837"/>
		<updated>2016-10-29T03:54:53Z</updated>

		<summary type="html">&lt;p&gt;Msardar: /* Testing Create Method */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;'''E1644: Refactor and Test 'Teams_Controller' Controller'''&amp;lt;ref&amp;gt;Project Description document https://google.com&amp;lt;/ref&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This page provides a brief description of the '''Expertiza''' project. The project is aimed at refactoring and testing the 'Teams_Controller' Controller, which contains the methods to create new teams, list the existing teams, create new teams by inheriting existing teams, deleting existing teams and creating multiple teams at once by assigning them random topics. The project entailed, refactoring some part of the controller to improve the readability of code and then creating test cases in [https://en.wikipedia.org/wiki/RSpec RSpec] to verify the methods it possesses. &lt;br /&gt;
&lt;br /&gt;
==Introduction to Expertiza==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a peer review based system which provides incremental learning from the class. This project has been developed together by faculty and students using [http://rubyonrails.org/ Ruby on Rails] framework. Expertiza allows the instructor to create, edit and delete assignments, create new assignment topics, assign them to a particular class or selected students, have students work on teams and then review each other's assignments at the end. For the students, they can signup for topics, form teams, and submit their projects and assignments. &lt;br /&gt;
Students then review the work done by other students and give suggestions to improve. Teams after reviews are allotted scores and they can refer to the peer comments to further improve their work. It also supports submission of different file types for assignments, including the URLs and wiki pages.&lt;br /&gt;
&lt;br /&gt;
== Project Description ==&lt;br /&gt;
'''Teams_Controller''' primarily handles the team creation, deletion and other behaviours. Most of those are called from the instructor’s view. When manual testing is done, most of the methods can be called by clicking the “Create teams” icon from both assignments and courses. &lt;br /&gt;
The following tasks have been performed as per the requirements.&lt;br /&gt;
&lt;br /&gt;
As a part of the project, some GUI's changes had to be made because they did not work the way they should have, some minor issues in the code were fixed and tests were written in '''RSpec''' for the methods delete, create, create teams, list and inherit.&lt;br /&gt;
&lt;br /&gt;
===Create Method===&lt;br /&gt;
The method '''Create''' is called when an instructor tries to create a team manually. This works for both, creating ''assignment teams'' and ''course teams''. Assignment teams are teams made to do a particular assignment together and ''Course Teams'' are teams which are made for the whole course.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to create course teams.&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to create assignment teams.&lt;br /&gt;
&lt;br /&gt;
===Delete Method===&lt;br /&gt;
The method '''Delete''' is called when an instructor tries to delete a team manually. This works for both, deleting ''assignment teams'' and ''course teams''.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to delete course teams.&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to delete assignment teams.&lt;br /&gt;
&lt;br /&gt;
===List Method===&lt;br /&gt;
The method '''List''' lists all the team nodes and the instructor is able to expand each team node to see the user nodes as well.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To check that all teams are being listed in the view.&lt;br /&gt;
&lt;br /&gt;
===Inherit Method===&lt;br /&gt;
The method '''Inherit''' inherits teams from course to assignments, but the “Inherit Teams From Course” option should not display when either 1) we are editing a course object or 2) the current assignment object does not have a course associated with it.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is displayed while creating an assignment team.&lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is not displayed while creating a course team. &lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is not displayed while creating teams for an assignment without a course.&lt;br /&gt;
&lt;br /&gt;
== Refactoring ==&lt;br /&gt;
'''Refactoring'''&amp;lt;ref&amp;gt;Refactoring https://en.wikipedia.org/wiki/Code_refactoring&amp;lt;/ref&amp;gt; is restructuring of code without the need of changing any external behavior. It reduces complexity and improves readability. It also becomes easy to extend the application with respect to different modules and their functionalities.&lt;br /&gt;
Some common techniques to refactor are:&lt;br /&gt;
&lt;br /&gt;
* Moving methods to appropriate modules&lt;br /&gt;
* Breaking methods into more meaningful functionality&lt;br /&gt;
* Creating more generalized code.&lt;br /&gt;
* Renaming methods and variable.&lt;br /&gt;
* Inheritance&lt;br /&gt;
&lt;br /&gt;
As the part of the project, the variable ''@signUps'' in the delete method in the teams_controller was changed to snake case, tp improve readability of code.&lt;br /&gt;
&lt;br /&gt;
== Changes to GUI == &lt;br /&gt;
To fix the view for ''inherit teams'' functionality, changes to the view were made.&lt;br /&gt;
&lt;br /&gt;
Initially, the code was:&lt;br /&gt;
&lt;br /&gt;
  Inherit Teams From Course&lt;br /&gt;
  Use the teams that are currently defined for the course.&lt;br /&gt;
 &amp;lt;%= form_tag :action =&amp;gt; 'inherit' do %&amp;gt;&lt;br /&gt;
   &amp;lt;%= hidden_field_tag 'id', @parent.id %&amp;gt;&lt;br /&gt;
   &amp;lt;%= submit_tag &amp;quot;Inherit&amp;quot; %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Which was changed to:&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;% if not @parent.instance_of?(Course) and not @parent.course.nil? %&amp;gt;&lt;br /&gt;
    Inherit Teams From Course &lt;br /&gt;
    Use the teams that are currently defined for the course.&lt;br /&gt;
   &amp;lt;%= form_tag :action =&amp;gt; 'inherit' do %&amp;gt;&lt;br /&gt;
     &amp;lt;%= hidden_field_tag 'id', @parent.id %&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
    &amp;lt;%= submit_tag &amp;quot;Inherit&amp;quot; %&amp;gt;&lt;br /&gt;
  &amp;lt;% end %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To fix the view, in the ''new.html.erb'' file of teams, we enclose the inherit teams section in an ''if condition'' that checks that the parent of the team is not a Course and it is not an Assignment whose course is nil.&lt;br /&gt;
&lt;br /&gt;
== Testing the Teams_Controller ==&lt;br /&gt;
&lt;br /&gt;
===Testing Inherit Method===&lt;br /&gt;
&lt;br /&gt;
To test that while creating an assignment team, the inherit teams section should be displayed, we login as instructor got to list page and click on Create Team Link. On this page we test that it should contain the string 'Inherit Teams From Course'.&lt;br /&gt;
&lt;br /&gt;
  it 'should display inherit teams while creating an assignment team' do&lt;br /&gt;
    create(:assignment)&lt;br /&gt;
    create(:assignment_node)&lt;br /&gt;
    create(:assignment_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)&lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Assignment'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
To test that while creating a course team, the inherit teams section should not be displayed, we do same steps as previous case but finally we test that the page does NOT contain 'Inherit Teams from Course'&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  it 'should not display inherit teams while creating a course team' do&lt;br /&gt;
    create(:course)&lt;br /&gt;
    create(:course_node)&lt;br /&gt;
    create(:course_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)&lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Course'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_no_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
Similiarly, for creating a team for an assignment without a course, we test that the page does not contain 'Inherit Teams From Course'. For this particular test case, we added a new factory object for that defined an assignment with course set to nil.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  it 'should not display inherit teams while creating team for an assignment without a course' do&lt;br /&gt;
    create(:assignment_without_course)&lt;br /&gt;
    create(:assignment_without_course_node)&lt;br /&gt;
    create(:assignment_without_course_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)    &lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Assignment'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_no_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
===Testing Create Method===&lt;br /&gt;
&lt;br /&gt;
This test checks that after creating an assignment team the count in the teams table increase by 1.&lt;br /&gt;
&lt;br /&gt;
    describe &amp;quot;POST #create&amp;quot; do&lt;br /&gt;
    context &amp;quot;with an assignment team&amp;quot; do&lt;br /&gt;
      it &amp;quot;increases count by 1&amp;quot; do	&lt;br /&gt;
        expect{create :assignment_team, assignment: @assignment}.to change(Team,:count).by(1)&lt;br /&gt;
      end&lt;br /&gt;
     it &amp;quot;redirects to the list page&amp;quot; do&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
   end&lt;br /&gt;
&lt;br /&gt;
The same test for a course team as well&lt;br /&gt;
&lt;br /&gt;
    context &amp;quot;with a course team&amp;quot; do&lt;br /&gt;
      it &amp;quot;increases the count by 1&amp;quot; do&lt;br /&gt;
        expect{create :course_team, course: @course}.to change(Team,:count).by(1)&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
===Testing Delete Method===&lt;br /&gt;
    &lt;br /&gt;
&lt;br /&gt;
   context &amp;quot;with an assignment team &amp;quot; do&lt;br /&gt;
      it &amp;quot;deletes an assignment team&amp;quot; do&lt;br /&gt;
        @assignment = create(:assignment)&lt;br /&gt;
        @a_team = create(:assignment_team)&lt;br /&gt;
        expect{ @a_team.delete }.to change(Team, :count).by(-1)&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
    &lt;br /&gt;
    context &amp;quot;with a course team &amp;quot; do&lt;br /&gt;
      it &amp;quot;deletes a course team&amp;quot; do&lt;br /&gt;
        @course = create(:course)&lt;br /&gt;
        @c_team = create(:course_team)&lt;br /&gt;
        expect{ @c_team.delete }.to change(Team, :count).by(-1)&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
===Testing List Method===&lt;br /&gt;
&lt;br /&gt;
 describe 'List Team' do&lt;br /&gt;
 &lt;br /&gt;
   it 'should list all team nodes' do&lt;br /&gt;
     create(:assignment)&lt;br /&gt;
     create(:assignment_node)&lt;br /&gt;
     assignment_team = create(:assignment_team)&lt;br /&gt;
    team_user = create(:team_user)&lt;br /&gt;
     login_as(&amp;quot;instructor6&amp;quot;)&lt;br /&gt;
     visit '/teams/list?id=1&amp;amp;type=Assignment'&lt;br /&gt;
     page.all('#theTable tr').each do |tr|&lt;br /&gt;
       expect(tr).to have_content?(assignment_team.name)&lt;br /&gt;
     end&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
==References==&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1644._Refactor_and_test_Teams_Controller&amp;diff=103828</id>
		<title>CSC/ECE 517 Fall 2016/E1644. Refactor and test Teams Controller</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1644._Refactor_and_test_Teams_Controller&amp;diff=103828"/>
		<updated>2016-10-29T03:50:53Z</updated>

		<summary type="html">&lt;p&gt;Msardar: /* Testing Inherit Method */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;'''E1644: Refactor and Test 'Teams_Controller' Controller'''&amp;lt;ref&amp;gt;Project Description document https://google.com&amp;lt;/ref&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This page provides a brief description of the '''Expertiza''' project. The project is aimed at refactoring and testing the 'Teams_Controller' Controller, which contains the methods to create new teams, list the existing teams, create new teams by inheriting existing teams, deleting existing teams and creating multiple teams at once by assigning them random topics. The project entailed, refactoring some part of the controller to improve the readability of code and then creating test cases in [https://en.wikipedia.org/wiki/RSpec RSpec] to verify the methods it possesses. &lt;br /&gt;
&lt;br /&gt;
==Introduction to Expertiza==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a peer review based system which provides incremental learning from the class. This project has been developed together by faculty and students using [http://rubyonrails.org/ Ruby on Rails] framework. Expertiza allows the instructor to create, edit and delete assignments, create new assignment topics, assign them to a particular class or selected students, have students work on teams and then review each other's assignments at the end. For the students, they can signup for topics, form teams, and submit their projects and assignments. &lt;br /&gt;
Students then review the work done by other students and give suggestions to improve. Teams after reviews are allotted scores and they can refer to the peer comments to further improve their work. It also supports submission of different file types for assignments, including the URLs and wiki pages.&lt;br /&gt;
&lt;br /&gt;
== Project Description ==&lt;br /&gt;
'''Teams_Controller''' primarily handles the team creation, deletion and other behaviours. Most of those are called from the instructor’s view. When manual testing is done, most of the methods can be called by clicking the “Create teams” icon from both assignments and courses. &lt;br /&gt;
The following tasks have been performed as per the requirements.&lt;br /&gt;
&lt;br /&gt;
As a part of the project, some GUI's changes had to be made because they did not work the way they should have, some minor issues in the code were fixed and tests were written in '''RSpec''' for the methods delete, create, create teams, list and inherit.&lt;br /&gt;
&lt;br /&gt;
===Create Method===&lt;br /&gt;
The method '''Create''' is called when an instructor tries to create a team manually. This works for both, creating ''assignment teams'' and ''course teams''. Assignment teams are teams made to do a particular assignment together and ''Course Teams'' are teams which are made for the whole course.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to create course teams.&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to create assignment teams.&lt;br /&gt;
&lt;br /&gt;
===Delete Method===&lt;br /&gt;
The method '''Delete''' is called when an instructor tries to delete a team manually. This works for both, deleting ''assignment teams'' and ''course teams''.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to delete course teams.&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to delete assignment teams.&lt;br /&gt;
&lt;br /&gt;
===List Method===&lt;br /&gt;
The method '''List''' lists all the team nodes and the instructor is able to expand each team node to see the user nodes as well.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To check that all teams are being listed in the view.&lt;br /&gt;
&lt;br /&gt;
===Inherit Method===&lt;br /&gt;
The method '''Inherit''' inherits teams from course to assignments, but the “Inherit Teams From Course” option should not display when either 1) we are editing a course object or 2) the current assignment object does not have a course associated with it.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is displayed while creating an assignment team.&lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is not displayed while creating a course team. &lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is not displayed while creating teams for an assignment without a course.&lt;br /&gt;
&lt;br /&gt;
== Refactoring ==&lt;br /&gt;
'''Refactoring'''&amp;lt;ref&amp;gt;Refactoring https://en.wikipedia.org/wiki/Code_refactoring&amp;lt;/ref&amp;gt; is restructuring of code without the need of changing any external behavior. It reduces complexity and improves readability. It also becomes easy to extend the application with respect to different modules and their functionalities.&lt;br /&gt;
Some common techniques to refactor are:&lt;br /&gt;
&lt;br /&gt;
* Moving methods to appropriate modules&lt;br /&gt;
* Breaking methods into more meaningful functionality&lt;br /&gt;
* Creating more generalized code.&lt;br /&gt;
* Renaming methods and variable.&lt;br /&gt;
* Inheritance&lt;br /&gt;
&lt;br /&gt;
As the part of the project, the variable ''@signUps'' in the delete method in the teams_controller was changed to snake case, tp improve readability of code.&lt;br /&gt;
&lt;br /&gt;
== Changes to GUI == &lt;br /&gt;
To fix the view for ''inherit teams'' functionality, changes to the view were made.&lt;br /&gt;
&lt;br /&gt;
Initially, the code was:&lt;br /&gt;
&lt;br /&gt;
  Inherit Teams From Course&lt;br /&gt;
  Use the teams that are currently defined for the course.&lt;br /&gt;
 &amp;lt;%= form_tag :action =&amp;gt; 'inherit' do %&amp;gt;&lt;br /&gt;
   &amp;lt;%= hidden_field_tag 'id', @parent.id %&amp;gt;&lt;br /&gt;
   &amp;lt;%= submit_tag &amp;quot;Inherit&amp;quot; %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Which was changed to:&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;% if not @parent.instance_of?(Course) and not @parent.course.nil? %&amp;gt;&lt;br /&gt;
    Inherit Teams From Course &lt;br /&gt;
    Use the teams that are currently defined for the course.&lt;br /&gt;
   &amp;lt;%= form_tag :action =&amp;gt; 'inherit' do %&amp;gt;&lt;br /&gt;
     &amp;lt;%= hidden_field_tag 'id', @parent.id %&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
    &amp;lt;%= submit_tag &amp;quot;Inherit&amp;quot; %&amp;gt;&lt;br /&gt;
  &amp;lt;% end %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To fix the view, in the ''new.html.erb'' file of teams, we enclose the inherit teams section in an ''if condition'' that checks that the parent of the team is not a Course and it is not an Assignment whose course is nil.&lt;br /&gt;
&lt;br /&gt;
== Testing the Teams_Controller ==&lt;br /&gt;
&lt;br /&gt;
===Testing Inherit Method===&lt;br /&gt;
&lt;br /&gt;
To test that while creating an assignment team, the inherit teams section should be displayed, we login as instructor got to list page and click on Create Team Link. On this page we test that it should contain the string 'Inherit Teams From Course'.&lt;br /&gt;
&lt;br /&gt;
  it 'should display inherit teams while creating an assignment team' do&lt;br /&gt;
    create(:assignment)&lt;br /&gt;
    create(:assignment_node)&lt;br /&gt;
    create(:assignment_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)&lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Assignment'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
To test that while creating a course team, the inherit teams section should not be displayed, we do same steps as previous case but finally we test that the page does NOT contain 'Inherit Teams from Course'&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  it 'should not display inherit teams while creating a course team' do&lt;br /&gt;
    create(:course)&lt;br /&gt;
    create(:course_node)&lt;br /&gt;
    create(:course_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)&lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Course'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_no_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
Similiarly, for creating a team for an assignment without a course, we test that the page does not contain 'Inherit Teams From Course'. For this particular test case, we added a new factory object for that defined an assignment with course set to nil.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  it 'should not display inherit teams while creating team for an assignment without a course' do&lt;br /&gt;
    create(:assignment_without_course)&lt;br /&gt;
    create(:assignment_without_course_node)&lt;br /&gt;
    create(:assignment_without_course_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)    &lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Assignment'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_no_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
===Testing Create Method===&lt;br /&gt;
&lt;br /&gt;
    describe &amp;quot;POST #create&amp;quot; do&lt;br /&gt;
    context &amp;quot;with an assignment team&amp;quot; do&lt;br /&gt;
      it &amp;quot;increases count by 1&amp;quot; do	&lt;br /&gt;
        expect{create :assignment_team, assignment: @assignment}.to change(Team,:count).by(1)&lt;br /&gt;
      end&lt;br /&gt;
     it &amp;quot;redirects to the list page&amp;quot; do&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
   end&lt;br /&gt;
&lt;br /&gt;
    &lt;br /&gt;
&lt;br /&gt;
    context &amp;quot;with a course team&amp;quot; do&lt;br /&gt;
      it &amp;quot;increases the count by 1&amp;quot; do&lt;br /&gt;
        expect{create :course_team, course: @course}.to change(Team,:count).by(1)&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
===Testing Delete Method===&lt;br /&gt;
    &lt;br /&gt;
&lt;br /&gt;
   context &amp;quot;with an assignment team &amp;quot; do&lt;br /&gt;
      it &amp;quot;deletes an assignment team&amp;quot; do&lt;br /&gt;
        @assignment = create(:assignment)&lt;br /&gt;
        @a_team = create(:assignment_team)&lt;br /&gt;
        expect{ @a_team.delete }.to change(Team, :count).by(-1)&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
    &lt;br /&gt;
    context &amp;quot;with a course team &amp;quot; do&lt;br /&gt;
      it &amp;quot;deletes a course team&amp;quot; do&lt;br /&gt;
        @course = create(:course)&lt;br /&gt;
        @c_team = create(:course_team)&lt;br /&gt;
        expect{ @c_team.delete }.to change(Team, :count).by(-1)&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
===Testing List Method===&lt;br /&gt;
&lt;br /&gt;
 describe 'List Team' do&lt;br /&gt;
 &lt;br /&gt;
   it 'should list all team nodes' do&lt;br /&gt;
     create(:assignment)&lt;br /&gt;
     create(:assignment_node)&lt;br /&gt;
     assignment_team = create(:assignment_team)&lt;br /&gt;
    team_user = create(:team_user)&lt;br /&gt;
     login_as(&amp;quot;instructor6&amp;quot;)&lt;br /&gt;
     visit '/teams/list?id=1&amp;amp;type=Assignment'&lt;br /&gt;
     page.all('#theTable tr').each do |tr|&lt;br /&gt;
       expect(tr).to have_content?(assignment_team.name)&lt;br /&gt;
     end&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
==References==&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1644._Refactor_and_test_Teams_Controller&amp;diff=103787</id>
		<title>CSC/ECE 517 Fall 2016/E1644. Refactor and test Teams Controller</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1644._Refactor_and_test_Teams_Controller&amp;diff=103787"/>
		<updated>2016-10-29T03:21:45Z</updated>

		<summary type="html">&lt;p&gt;Msardar: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;'''E1644: Refactor and Test 'Teams_Controller' Controller'''&amp;lt;ref&amp;gt;Project Description document https://google.com&amp;lt;/ref&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This page provides a brief description of the '''Expertiza''' project. The project is aimed at refactoring and testing the 'Teams_Controller' Controller, which contains the methods to create new teams, list the existing teams, create new teams by inheriting existing teams, deleting existing teams and creating multiple teams at once by assigning them random topics. The project entailed, refactoring some part of the controller to improve the readability of code and then creating test cases in [https://en.wikipedia.org/wiki/RSpec RSpec] to verify the methods it possesses. &lt;br /&gt;
&lt;br /&gt;
==Introduction to Expertiza==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a peer review based system which provides incremental learning from the class. This project has been developed together by faculty and students using [http://rubyonrails.org/ Ruby on Rails] framework. Expertiza allows the instructor to create, edit and delete assignments, create new assignment topics, assign them to a particular class or selected students, have students work on teams and then review each other's assignments at the end. For the students, they can signup for topics, form teams, and submit their projects and assignments. &lt;br /&gt;
Students then review the work done by other students and give suggestions to improve. Teams after reviews are allotted scores and they can refer to the peer comments to further improve their work. It also supports submission of different file types for assignments, including the URLs and wiki pages.&lt;br /&gt;
&lt;br /&gt;
== Project Description ==&lt;br /&gt;
'''Teams_Controller''' primarily handles the team creation, deletion and other behaviours. Most of those are called from the instructor’s view. When manual testing is done, most of the methods can be called by clicking the “Create teams” icon from both assignments and courses. &lt;br /&gt;
The following tasks have been performed as per the requirements.&lt;br /&gt;
&lt;br /&gt;
As a part of the project, some GUI's changes had to be made because they did not work the way they should have, some minor issues in the code were fixed and tests were written in '''RSpec''' for the methods delete, create, create teams, list and inherit.&lt;br /&gt;
&lt;br /&gt;
===Create Method===&lt;br /&gt;
The method '''Create''' is called when an instructor tries to create a team manually. This works for both, creating ''assignment teams'' and ''course teams''. Assignment teams are teams made to do a particular assignment together and ''Course Teams'' are teams which are made for the whole course.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to create course teams.&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to create assignment teams.&lt;br /&gt;
&lt;br /&gt;
===Delete Method===&lt;br /&gt;
The method '''Delete''' is called when an instructor tries to delete a team manually. This works for both, deleting ''assignment teams'' and ''course teams''.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to delete course teams.&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to delete assignment teams.&lt;br /&gt;
&lt;br /&gt;
===List Method===&lt;br /&gt;
The method '''List''' lists all the team nodes and the instructor is able to expand each team node to see the user nodes as well.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To check that all teams are being listed in the view.&lt;br /&gt;
&lt;br /&gt;
===Inherit Method===&lt;br /&gt;
The method '''Inherit''' inherits teams from course to assignments, but the “Inherit Teams From Course” option should not display when either 1) we are editing a course object or 2) the current assignment object does not have a course associated with it.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is displayed while creating an assignment team.&lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is not displayed while creating a course team. &lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is not displayed while creating teams for an assignment without a course.&lt;br /&gt;
&lt;br /&gt;
== Refactoring ==&lt;br /&gt;
'''Refactoring'''&amp;lt;ref&amp;gt;Refactoring https://en.wikipedia.org/wiki/Code_refactoring&amp;lt;/ref&amp;gt; is restructuring of code without the need of changing any external behavior. It reduces complexity and improves readability. It also becomes easy to extend the application with respect to different modules and their functionalities.&lt;br /&gt;
Some common techniques to refactor are:&lt;br /&gt;
&lt;br /&gt;
* Moving methods to appropriate modules&lt;br /&gt;
* Breaking methods into more meaningful functionality&lt;br /&gt;
* Creating more generalized code.&lt;br /&gt;
* Renaming methods and variable.&lt;br /&gt;
* Inheritance&lt;br /&gt;
&lt;br /&gt;
As the part of the project, the variable ''@signUps'' in the delete method in the teams_controller was changed to snake case, tp improve readability of code.&lt;br /&gt;
&lt;br /&gt;
== Changes to GUI == &lt;br /&gt;
To fix the view for ''inherit teams'' functionality, changes to the view were made.&lt;br /&gt;
&lt;br /&gt;
Initially, the code was:&lt;br /&gt;
&lt;br /&gt;
  Inherit Teams From Course&lt;br /&gt;
  Use the teams that are currently defined for the course.&lt;br /&gt;
 &amp;lt;%= form_tag :action =&amp;gt; 'inherit' do %&amp;gt;&lt;br /&gt;
   &amp;lt;%= hidden_field_tag 'id', @parent.id %&amp;gt;&lt;br /&gt;
   &amp;lt;%= submit_tag &amp;quot;Inherit&amp;quot; %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Which was changed to:&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;% if not @parent.instance_of?(Course) and not @parent.course.nil? %&amp;gt;&lt;br /&gt;
    Inherit Teams From Course &lt;br /&gt;
    Use the teams that are currently defined for the course.&lt;br /&gt;
   &amp;lt;%= form_tag :action =&amp;gt; 'inherit' do %&amp;gt;&lt;br /&gt;
     &amp;lt;%= hidden_field_tag 'id', @parent.id %&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
    &amp;lt;%= submit_tag &amp;quot;Inherit&amp;quot; %&amp;gt;&lt;br /&gt;
  &amp;lt;% end %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To fix the view, in the ''new.html.erb'' file of teams, we enclose the inherit teams section in an ''if condition'' that checks that the parent of the team is not a Course and it is not an Assignment whose course is nil.&lt;br /&gt;
&lt;br /&gt;
== Testing the Teams_Controller ==&lt;br /&gt;
&lt;br /&gt;
===Testing Inherit Method===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  it 'should display inherit teams while creating an assignment team' do&lt;br /&gt;
    create(:assignment)&lt;br /&gt;
    create(:assignment_node)&lt;br /&gt;
    create(:assignment_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)&lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Assignment'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  it 'should not display inherit teams while creating a course team' do&lt;br /&gt;
    create(:course)&lt;br /&gt;
    create(:course_node)&lt;br /&gt;
    create(:course_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)&lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Course'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_no_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  it 'should not display inherit teams while creating team for an assignment without a course' do&lt;br /&gt;
    create(:assignment_without_course)&lt;br /&gt;
    create(:assignment_without_course_node)&lt;br /&gt;
    create(:assignment_without_course_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)    &lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Assignment'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_no_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
===Testing Create Method===&lt;br /&gt;
&lt;br /&gt;
    describe &amp;quot;POST #create&amp;quot; do&lt;br /&gt;
    context &amp;quot;with an assignment team&amp;quot; do&lt;br /&gt;
      it &amp;quot;increases count by 1&amp;quot; do	&lt;br /&gt;
        expect{create :assignment_team, assignment: @assignment}.to change(Team,:count).by(1)&lt;br /&gt;
      end&lt;br /&gt;
     it &amp;quot;redirects to the list page&amp;quot; do&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
   end&lt;br /&gt;
&lt;br /&gt;
    &lt;br /&gt;
&lt;br /&gt;
    context &amp;quot;with a course team&amp;quot; do&lt;br /&gt;
      it &amp;quot;increases the count by 1&amp;quot; do&lt;br /&gt;
        expect{create :course_team, course: @course}.to change(Team,:count).by(1)&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
===Testing Delete Method===&lt;br /&gt;
    &lt;br /&gt;
&lt;br /&gt;
   context &amp;quot;with an assignment team &amp;quot; do&lt;br /&gt;
      it &amp;quot;deletes an assignment team&amp;quot; do&lt;br /&gt;
        @assignment = create(:assignment)&lt;br /&gt;
        @a_team = create(:assignment_team)&lt;br /&gt;
        expect{ @a_team.delete }.to change(Team, :count).by(-1)&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
    &lt;br /&gt;
    context &amp;quot;with a course team &amp;quot; do&lt;br /&gt;
      it &amp;quot;deletes a course team&amp;quot; do&lt;br /&gt;
        @course = create(:course)&lt;br /&gt;
        @c_team = create(:course_team)&lt;br /&gt;
        expect{ @c_team.delete }.to change(Team, :count).by(-1)&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
===Testing List Method===&lt;br /&gt;
&lt;br /&gt;
 describe 'List Team' do&lt;br /&gt;
 &lt;br /&gt;
   it 'should list all team nodes' do&lt;br /&gt;
     create(:assignment)&lt;br /&gt;
     create(:assignment_node)&lt;br /&gt;
     assignment_team = create(:assignment_team)&lt;br /&gt;
    team_user = create(:team_user)&lt;br /&gt;
     login_as(&amp;quot;instructor6&amp;quot;)&lt;br /&gt;
     visit '/teams/list?id=1&amp;amp;type=Assignment'&lt;br /&gt;
     page.all('#theTable tr').each do |tr|&lt;br /&gt;
       expect(tr).to have_content?(assignment_team.name)&lt;br /&gt;
     end&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
==References==&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1644._Refactor_and_test_Teams_Controller&amp;diff=103785</id>
		<title>CSC/ECE 517 Fall 2016/E1644. Refactor and test Teams Controller</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1644._Refactor_and_test_Teams_Controller&amp;diff=103785"/>
		<updated>2016-10-29T03:20:53Z</updated>

		<summary type="html">&lt;p&gt;Msardar: /* Testing List Method */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;'''E1644. Refactor and Test 'Teams_Controller' Controller'''&amp;lt;ref&amp;gt;Project Description document https://google.com&amp;lt;/ref&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This page provides a brief description of the '''Expertiza''' project. The project is aimed at refactoring and testing the 'Teams_Controller' Controller, which contains the methods to create new teams, list the existing teams, create new teams by inheriting existing teams, deleting existing teams and creating multiple teams at once by assigning them random topics. The project entailed, refactoring some part of the controller to improve the readability of code and then creating test cases in [https://en.wikipedia.org/wiki/RSpec RSpec] to verify the methods it possesses. &lt;br /&gt;
&lt;br /&gt;
==Introduction to Expertiza==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a peer review based system which provides incremental learning from the class. This project has been developed together by faculty and students using [http://rubyonrails.org/ Ruby on Rails] framework. Expertiza allows the instructor to create, edit and delete assignments, create new assignment topics, assign them to a particular class or selected students, have students work on teams and then review each other's assignments at the end. For the students, they can signup for topics, form teams, and submit their projects and assignments. &lt;br /&gt;
Students then review the work done by other students and give suggestions to improve. Teams after reviews are allotted scores and they can refer to the peer comments to further improve their work. It also supports submission of different file types for assignments, including the URLs and wiki pages.&lt;br /&gt;
&lt;br /&gt;
== Project Description ==&lt;br /&gt;
'''Teams_Controller''' primarily handles the team creation, deletion and other behaviours. Most of those are called from the instructor’s view. When manual testing is done, most of the methods can be called by clicking the “Create teams” icon from both assignments and courses. &lt;br /&gt;
The following tasks have been performed as per the requirements.&lt;br /&gt;
&lt;br /&gt;
As a part of the project, some GUI's changes had to be made because they did not work the way they should have, some minor issues in the code were fixed and tests were written in '''RSpec''' for the methods delete, create, create teams, list and inherit.&lt;br /&gt;
&lt;br /&gt;
===Create Method===&lt;br /&gt;
The method '''Create''' is called when an instructor tries to create a team manually. This works for both, creating ''assignment teams'' and ''course teams''. Assignment teams are teams made to do a particular assignment together and ''Course Teams'' are teams which are made for the whole course.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to create course teams.&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to create assignment teams.&lt;br /&gt;
&lt;br /&gt;
===Delete Method===&lt;br /&gt;
The method '''Delete''' is called when an instructor tries to delete a team manually. This works for both, deleting ''assignment teams'' and ''course teams''.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to delete course teams.&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to delete assignment teams.&lt;br /&gt;
&lt;br /&gt;
===List Method===&lt;br /&gt;
The method '''List''' lists all the team nodes and the instructor is able to expand each team node to see the user nodes as well.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To check that all teams are being listed in the view.&lt;br /&gt;
&lt;br /&gt;
===Inherit Method===&lt;br /&gt;
The method '''Inherit''' inherits teams from course to assignments, but the “Inherit Teams From Course” option should not display when either 1) we are editing a course object or 2) the current assignment object does not have a course associated with it.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is displayed while creating an assignment team.&lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is not displayed while creating a course team. &lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is not displayed while creating teams for an assignment without a course.&lt;br /&gt;
&lt;br /&gt;
== Refactoring ==&lt;br /&gt;
'''Refactoring'''&amp;lt;ref&amp;gt;Refactoring https://en.wikipedia.org/wiki/Code_refactoring&amp;lt;/ref&amp;gt; is restructuring of code without the need of changing any external behavior. It reduces complexity and improves readability. It also becomes easy to extend the application with respect to different modules and their functionalities.&lt;br /&gt;
Some common techniques to refactor are:&lt;br /&gt;
&lt;br /&gt;
* Moving methods to appropriate modules&lt;br /&gt;
* Breaking methods into more meaningful functionality&lt;br /&gt;
* Creating more generalized code.&lt;br /&gt;
* Renaming methods and variable.&lt;br /&gt;
* Inheritance&lt;br /&gt;
&lt;br /&gt;
As the part of the project, the variable ''@signUps'' in the delete method in the teams_controller was changed to snake case, tp improve readability of code.&lt;br /&gt;
&lt;br /&gt;
== Changes to GUI == &lt;br /&gt;
To fix the view for ''inherit teams'' functionality, changes to the view were made.&lt;br /&gt;
&lt;br /&gt;
Initially, the code was:&lt;br /&gt;
&lt;br /&gt;
  Inherit Teams From Course&lt;br /&gt;
  Use the teams that are currently defined for the course.&lt;br /&gt;
 &amp;lt;%= form_tag :action =&amp;gt; 'inherit' do %&amp;gt;&lt;br /&gt;
   &amp;lt;%= hidden_field_tag 'id', @parent.id %&amp;gt;&lt;br /&gt;
   &amp;lt;%= submit_tag &amp;quot;Inherit&amp;quot; %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Which was changed to:&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;% if not @parent.instance_of?(Course) and not @parent.course.nil? %&amp;gt;&lt;br /&gt;
    Inherit Teams From Course &lt;br /&gt;
    Use the teams that are currently defined for the course.&lt;br /&gt;
   &amp;lt;%= form_tag :action =&amp;gt; 'inherit' do %&amp;gt;&lt;br /&gt;
     &amp;lt;%= hidden_field_tag 'id', @parent.id %&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
    &amp;lt;%= submit_tag &amp;quot;Inherit&amp;quot; %&amp;gt;&lt;br /&gt;
  &amp;lt;% end %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To fix the view, in the ''new.html.erb'' file of teams, we enclose the inherit teams section in an ''if condition'' that checks that the parent of the team is not a Course and it is not an Assignment whose course is nil.&lt;br /&gt;
&lt;br /&gt;
== Testing the Teams_Controller ==&lt;br /&gt;
&lt;br /&gt;
===Testing Inherit Method===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  it 'should display inherit teams while creating an assignment team' do&lt;br /&gt;
    create(:assignment)&lt;br /&gt;
    create(:assignment_node)&lt;br /&gt;
    create(:assignment_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)&lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Assignment'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  it 'should not display inherit teams while creating a course team' do&lt;br /&gt;
    create(:course)&lt;br /&gt;
    create(:course_node)&lt;br /&gt;
    create(:course_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)&lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Course'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_no_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  it 'should not display inherit teams while creating team for an assignment without a course' do&lt;br /&gt;
    create(:assignment_without_course)&lt;br /&gt;
    create(:assignment_without_course_node)&lt;br /&gt;
    create(:assignment_without_course_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)    &lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Assignment'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_no_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
===Testing Create Method===&lt;br /&gt;
&lt;br /&gt;
    describe &amp;quot;POST #create&amp;quot; do&lt;br /&gt;
    context &amp;quot;with an assignment team&amp;quot; do&lt;br /&gt;
      it &amp;quot;increases count by 1&amp;quot; do	&lt;br /&gt;
        expect{create :assignment_team, assignment: @assignment}.to change(Team,:count).by(1)&lt;br /&gt;
      end&lt;br /&gt;
     it &amp;quot;redirects to the list page&amp;quot; do&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
   end&lt;br /&gt;
&lt;br /&gt;
    &lt;br /&gt;
&lt;br /&gt;
    context &amp;quot;with a course team&amp;quot; do&lt;br /&gt;
      it &amp;quot;increases the count by 1&amp;quot; do&lt;br /&gt;
        expect{create :course_team, course: @course}.to change(Team,:count).by(1)&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
===Testing Delete Method===&lt;br /&gt;
    &lt;br /&gt;
&lt;br /&gt;
   context &amp;quot;with an assignment team &amp;quot; do&lt;br /&gt;
      it &amp;quot;deletes an assignment team&amp;quot; do&lt;br /&gt;
        @assignment = create(:assignment)&lt;br /&gt;
        @a_team = create(:assignment_team)&lt;br /&gt;
        expect{ @a_team.delete }.to change(Team, :count).by(-1)&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
    &lt;br /&gt;
    context &amp;quot;with a course team &amp;quot; do&lt;br /&gt;
      it &amp;quot;deletes a course team&amp;quot; do&lt;br /&gt;
        @course = create(:course)&lt;br /&gt;
        @c_team = create(:course_team)&lt;br /&gt;
        expect{ @c_team.delete }.to change(Team, :count).by(-1)&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
===Testing List Method===&lt;br /&gt;
&lt;br /&gt;
 describe 'List Team' do&lt;br /&gt;
 &lt;br /&gt;
   it 'should list all team nodes' do&lt;br /&gt;
     create(:assignment)&lt;br /&gt;
     create(:assignment_node)&lt;br /&gt;
     assignment_team = create(:assignment_team)&lt;br /&gt;
    team_user = create(:team_user)&lt;br /&gt;
     login_as(&amp;quot;instructor6&amp;quot;)&lt;br /&gt;
     visit '/teams/list?id=1&amp;amp;type=Assignment'&lt;br /&gt;
     page.all('#theTable tr').each do |tr|&lt;br /&gt;
       expect(tr).to have_content?(assignment_team.name)&lt;br /&gt;
     end&lt;br /&gt;
    end&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
==References==&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1644._Refactor_and_test_Teams_Controller&amp;diff=103779</id>
		<title>CSC/ECE 517 Fall 2016/E1644. Refactor and test Teams Controller</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1644._Refactor_and_test_Teams_Controller&amp;diff=103779"/>
		<updated>2016-10-29T03:18:05Z</updated>

		<summary type="html">&lt;p&gt;Msardar: /* Testing Delete Method */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;'''E1644. Refactor and Test 'Teams_Controller' Controller'''&amp;lt;ref&amp;gt;Project Description document https://google.com&amp;lt;/ref&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This page provides a brief description of the '''Expertiza''' project. The project is aimed at refactoring and testing the 'Teams_Controller' Controller, which contains the methods to create new teams, list the existing teams, create new teams by inheriting existing teams, deleting existing teams and creating multiple teams at once by assigning them random topics. The project entailed, refactoring some part of the controller to improve the readability of code and then creating test cases in [https://en.wikipedia.org/wiki/RSpec RSpec] to verify the methods it possesses. &lt;br /&gt;
&lt;br /&gt;
==Introduction to Expertiza==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a peer review based system which provides incremental learning from the class. This project has been developed together by faculty and students using [http://rubyonrails.org/ Ruby on Rails] framework. Expertiza allows the instructor to create, edit and delete assignments, create new assignment topics, assign them to a particular class or selected students, have students work on teams and then review each other's assignments at the end. For the students, they can signup for topics, form teams, and submit their projects and assignments. &lt;br /&gt;
Students then review the work done by other students and give suggestions to improve. Teams after reviews are allotted scores and they can refer to the peer comments to further improve their work. It also supports submission of different file types for assignments, including the URLs and wiki pages.&lt;br /&gt;
&lt;br /&gt;
== Project Description ==&lt;br /&gt;
'''Teams_Controller''' primarily handles the team creation, deletion and other behaviours. Most of those are called from the instructor’s view. When manual testing is done, most of the methods can be called by clicking the “Create teams” icon from both assignments and courses. &lt;br /&gt;
The following tasks have been performed as per the requirements.&lt;br /&gt;
&lt;br /&gt;
As a part of the project, some GUI's changes had to be made because they did not work the way they should have, some minor issues in the code were fixed and tests were written in '''RSpec''' for the methods delete, create, create teams, list and inherit.&lt;br /&gt;
&lt;br /&gt;
===Create Method===&lt;br /&gt;
The method '''Create''' is called when an instructor tries to create a team manually. This works for both, creating ''assignment teams'' and ''course teams''. Assignment teams are teams made to do a particular assignment together and ''Course Teams'' are teams which are made for the whole course.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to create course teams.&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to create assignment teams.&lt;br /&gt;
&lt;br /&gt;
===Delete Method===&lt;br /&gt;
The method '''Delete''' is called when an instructor tries to delete a team manually. This works for both, deleting ''assignment teams'' and ''course teams''.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to delete course teams.&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to delete assignment teams.&lt;br /&gt;
&lt;br /&gt;
===List Method===&lt;br /&gt;
The method '''List''' lists all the team nodes and the instructor is able to expand each team node to see the user nodes as well.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To check that all teams are being listed in the view.&lt;br /&gt;
&lt;br /&gt;
===Inherit Method===&lt;br /&gt;
The method '''Inherit''' inherits teams from course to assignments, but the “Inherit Teams From Course” option should not display when either 1) we are editing a course object or 2) the current assignment object does not have a course associated with it.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is displayed while creating an assignment team.&lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is not displayed while creating a course team. &lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is not displayed while creating teams for an assignment without a course.&lt;br /&gt;
&lt;br /&gt;
== Refactoring ==&lt;br /&gt;
'''Refactoring'''&amp;lt;ref&amp;gt;Refactoring https://en.wikipedia.org/wiki/Code_refactoring&amp;lt;/ref&amp;gt; is restructuring of code without the need of changing any external behavior. It reduces complexity and improves readability. It also becomes easy to extend the application with respect to different modules and their functionalities.&lt;br /&gt;
Some common techniques to refactor are:&lt;br /&gt;
&lt;br /&gt;
* Moving methods to appropriate modules&lt;br /&gt;
* Breaking methods into more meaningful functionality&lt;br /&gt;
* Creating more generalized code.&lt;br /&gt;
* Renaming methods and variable.&lt;br /&gt;
* Inheritance&lt;br /&gt;
&lt;br /&gt;
As the part of the project, the variable ''@signUps'' in the delete method in the teams_controller was changed to snake case, tp improve readability of code.&lt;br /&gt;
&lt;br /&gt;
== Changes to GUI == &lt;br /&gt;
To fix the view for ''inherit teams'' functionality, changes to the view were made.&lt;br /&gt;
&lt;br /&gt;
Initially, the code was:&lt;br /&gt;
&lt;br /&gt;
  Inherit Teams From Course&lt;br /&gt;
  Use the teams that are currently defined for the course.&lt;br /&gt;
 &amp;lt;%= form_tag :action =&amp;gt; 'inherit' do %&amp;gt;&lt;br /&gt;
   &amp;lt;%= hidden_field_tag 'id', @parent.id %&amp;gt;&lt;br /&gt;
   &amp;lt;%= submit_tag &amp;quot;Inherit&amp;quot; %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Which was changed to:&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;% if not @parent.instance_of?(Course) and not @parent.course.nil? %&amp;gt;&lt;br /&gt;
    Inherit Teams From Course &lt;br /&gt;
    Use the teams that are currently defined for the course.&lt;br /&gt;
   &amp;lt;%= form_tag :action =&amp;gt; 'inherit' do %&amp;gt;&lt;br /&gt;
     &amp;lt;%= hidden_field_tag 'id', @parent.id %&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
    &amp;lt;%= submit_tag &amp;quot;Inherit&amp;quot; %&amp;gt;&lt;br /&gt;
  &amp;lt;% end %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To fix the view, in the ''new.html.erb'' file of teams, we enclose the inherit teams section in an ''if condition'' that checks that the parent of the team is not a Course and it is not an Assignment whose course is nil.&lt;br /&gt;
&lt;br /&gt;
== Testing the Teams_Controller ==&lt;br /&gt;
&lt;br /&gt;
===Testing Inherit Method===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  it 'should display inherit teams while creating an assignment team' do&lt;br /&gt;
    create(:assignment)&lt;br /&gt;
    create(:assignment_node)&lt;br /&gt;
    create(:assignment_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)&lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Assignment'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  it 'should not display inherit teams while creating a course team' do&lt;br /&gt;
    create(:course)&lt;br /&gt;
    create(:course_node)&lt;br /&gt;
    create(:course_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)&lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Course'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_no_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  it 'should not display inherit teams while creating team for an assignment without a course' do&lt;br /&gt;
    create(:assignment_without_course)&lt;br /&gt;
    create(:assignment_without_course_node)&lt;br /&gt;
    create(:assignment_without_course_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)    &lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Assignment'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_no_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
===Testing Create Method===&lt;br /&gt;
&lt;br /&gt;
    describe &amp;quot;POST #create&amp;quot; do&lt;br /&gt;
    context &amp;quot;with an assignment team&amp;quot; do&lt;br /&gt;
      it &amp;quot;increases count by 1&amp;quot; do	&lt;br /&gt;
        expect{create :assignment_team, assignment: @assignment}.to change(Team,:count).by(1)&lt;br /&gt;
      end&lt;br /&gt;
     it &amp;quot;redirects to the list page&amp;quot; do&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
   end&lt;br /&gt;
&lt;br /&gt;
    &lt;br /&gt;
&lt;br /&gt;
    context &amp;quot;with a course team&amp;quot; do&lt;br /&gt;
      it &amp;quot;increases the count by 1&amp;quot; do&lt;br /&gt;
        expect{create :course_team, course: @course}.to change(Team,:count).by(1)&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
===Testing Delete Method===&lt;br /&gt;
    &lt;br /&gt;
&lt;br /&gt;
   context &amp;quot;with an assignment team &amp;quot; do&lt;br /&gt;
      it &amp;quot;deletes an assignment team&amp;quot; do&lt;br /&gt;
        @assignment = create(:assignment)&lt;br /&gt;
        @a_team = create(:assignment_team)&lt;br /&gt;
        expect{ @a_team.delete }.to change(Team, :count).by(-1)&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
    &lt;br /&gt;
    context &amp;quot;with a course team &amp;quot; do&lt;br /&gt;
      it &amp;quot;deletes a course team&amp;quot; do&lt;br /&gt;
        @course = create(:course)&lt;br /&gt;
        @c_team = create(:course_team)&lt;br /&gt;
        expect{ @c_team.delete }.to change(Team, :count).by(-1)&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
===Testing List Method===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==References==&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1644._Refactor_and_test_Teams_Controller&amp;diff=103778</id>
		<title>CSC/ECE 517 Fall 2016/E1644. Refactor and test Teams Controller</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1644._Refactor_and_test_Teams_Controller&amp;diff=103778"/>
		<updated>2016-10-29T03:17:32Z</updated>

		<summary type="html">&lt;p&gt;Msardar: /* Testing Delete Method */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;'''E1644. Refactor and Test 'Teams_Controller' Controller'''&amp;lt;ref&amp;gt;Project Description document https://google.com&amp;lt;/ref&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This page provides a brief description of the '''Expertiza''' project. The project is aimed at refactoring and testing the 'Teams_Controller' Controller, which contains the methods to create new teams, list the existing teams, create new teams by inheriting existing teams, deleting existing teams and creating multiple teams at once by assigning them random topics. The project entailed, refactoring some part of the controller to improve the readability of code and then creating test cases in [https://en.wikipedia.org/wiki/RSpec RSpec] to verify the methods it possesses. &lt;br /&gt;
&lt;br /&gt;
==Introduction to Expertiza==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a peer review based system which provides incremental learning from the class. This project has been developed together by faculty and students using [http://rubyonrails.org/ Ruby on Rails] framework. Expertiza allows the instructor to create, edit and delete assignments, create new assignment topics, assign them to a particular class or selected students, have students work on teams and then review each other's assignments at the end. For the students, they can signup for topics, form teams, and submit their projects and assignments. &lt;br /&gt;
Students then review the work done by other students and give suggestions to improve. Teams after reviews are allotted scores and they can refer to the peer comments to further improve their work. It also supports submission of different file types for assignments, including the URLs and wiki pages.&lt;br /&gt;
&lt;br /&gt;
== Project Description ==&lt;br /&gt;
'''Teams_Controller''' primarily handles the team creation, deletion and other behaviours. Most of those are called from the instructor’s view. When manual testing is done, most of the methods can be called by clicking the “Create teams” icon from both assignments and courses. &lt;br /&gt;
The following tasks have been performed as per the requirements.&lt;br /&gt;
&lt;br /&gt;
As a part of the project, some GUI's changes had to be made because they did not work the way they should have, some minor issues in the code were fixed and tests were written in '''RSpec''' for the methods delete, create, create teams, list and inherit.&lt;br /&gt;
&lt;br /&gt;
===Create Method===&lt;br /&gt;
The method '''Create''' is called when an instructor tries to create a team manually. This works for both, creating ''assignment teams'' and ''course teams''. Assignment teams are teams made to do a particular assignment together and ''Course Teams'' are teams which are made for the whole course.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to create course teams.&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to create assignment teams.&lt;br /&gt;
&lt;br /&gt;
===Delete Method===&lt;br /&gt;
The method '''Delete''' is called when an instructor tries to delete a team manually. This works for both, deleting ''assignment teams'' and ''course teams''.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to delete course teams.&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to delete assignment teams.&lt;br /&gt;
&lt;br /&gt;
===List Method===&lt;br /&gt;
The method '''List''' lists all the team nodes and the instructor is able to expand each team node to see the user nodes as well.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To check that all teams are being listed in the view.&lt;br /&gt;
&lt;br /&gt;
===Inherit Method===&lt;br /&gt;
The method '''Inherit''' inherits teams from course to assignments, but the “Inherit Teams From Course” option should not display when either 1) we are editing a course object or 2) the current assignment object does not have a course associated with it.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is displayed while creating an assignment team.&lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is not displayed while creating a course team. &lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is not displayed while creating teams for an assignment without a course.&lt;br /&gt;
&lt;br /&gt;
== Refactoring ==&lt;br /&gt;
'''Refactoring'''&amp;lt;ref&amp;gt;Refactoring https://en.wikipedia.org/wiki/Code_refactoring&amp;lt;/ref&amp;gt; is restructuring of code without the need of changing any external behavior. It reduces complexity and improves readability. It also becomes easy to extend the application with respect to different modules and their functionalities.&lt;br /&gt;
Some common techniques to refactor are:&lt;br /&gt;
&lt;br /&gt;
* Moving methods to appropriate modules&lt;br /&gt;
* Breaking methods into more meaningful functionality&lt;br /&gt;
* Creating more generalized code.&lt;br /&gt;
* Renaming methods and variable.&lt;br /&gt;
* Inheritance&lt;br /&gt;
&lt;br /&gt;
As the part of the project, the variable ''@signUps'' in the delete method in the teams_controller was changed to snake case, tp improve readability of code.&lt;br /&gt;
&lt;br /&gt;
== Changes to GUI == &lt;br /&gt;
To fix the view for ''inherit teams'' functionality, changes to the view were made.&lt;br /&gt;
&lt;br /&gt;
Initially, the code was:&lt;br /&gt;
&lt;br /&gt;
  Inherit Teams From Course&lt;br /&gt;
  Use the teams that are currently defined for the course.&lt;br /&gt;
 &amp;lt;%= form_tag :action =&amp;gt; 'inherit' do %&amp;gt;&lt;br /&gt;
   &amp;lt;%= hidden_field_tag 'id', @parent.id %&amp;gt;&lt;br /&gt;
   &amp;lt;%= submit_tag &amp;quot;Inherit&amp;quot; %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Which was changed to:&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;% if not @parent.instance_of?(Course) and not @parent.course.nil? %&amp;gt;&lt;br /&gt;
    Inherit Teams From Course &lt;br /&gt;
    Use the teams that are currently defined for the course.&lt;br /&gt;
   &amp;lt;%= form_tag :action =&amp;gt; 'inherit' do %&amp;gt;&lt;br /&gt;
     &amp;lt;%= hidden_field_tag 'id', @parent.id %&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
    &amp;lt;%= submit_tag &amp;quot;Inherit&amp;quot; %&amp;gt;&lt;br /&gt;
  &amp;lt;% end %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To fix the view, in the ''new.html.erb'' file of teams, we enclose the inherit teams section in an ''if condition'' that checks that the parent of the team is not a Course and it is not an Assignment whose course is nil.&lt;br /&gt;
&lt;br /&gt;
== Testing the Teams_Controller ==&lt;br /&gt;
&lt;br /&gt;
===Testing Inherit Method===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  it 'should display inherit teams while creating an assignment team' do&lt;br /&gt;
    create(:assignment)&lt;br /&gt;
    create(:assignment_node)&lt;br /&gt;
    create(:assignment_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)&lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Assignment'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  it 'should not display inherit teams while creating a course team' do&lt;br /&gt;
    create(:course)&lt;br /&gt;
    create(:course_node)&lt;br /&gt;
    create(:course_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)&lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Course'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_no_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  it 'should not display inherit teams while creating team for an assignment without a course' do&lt;br /&gt;
    create(:assignment_without_course)&lt;br /&gt;
    create(:assignment_without_course_node)&lt;br /&gt;
    create(:assignment_without_course_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)    &lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Assignment'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_no_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
===Testing Create Method===&lt;br /&gt;
&lt;br /&gt;
    describe &amp;quot;POST #create&amp;quot; do&lt;br /&gt;
    context &amp;quot;with an assignment team&amp;quot; do&lt;br /&gt;
      it &amp;quot;increases count by 1&amp;quot; do	&lt;br /&gt;
        expect{create :assignment_team, assignment: @assignment}.to change(Team,:count).by(1)&lt;br /&gt;
      end&lt;br /&gt;
     it &amp;quot;redirects to the list page&amp;quot; do&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
   end&lt;br /&gt;
&lt;br /&gt;
    &lt;br /&gt;
&lt;br /&gt;
    context &amp;quot;with a course team&amp;quot; do&lt;br /&gt;
      it &amp;quot;increases the count by 1&amp;quot; do&lt;br /&gt;
        expect{create :course_team, course: @course}.to change(Team,:count).by(1)&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
===Testing Delete Method===&lt;br /&gt;
    &lt;br /&gt;
&lt;br /&gt;
   context &amp;quot;with an assignment team &amp;quot; do&lt;br /&gt;
      it &amp;quot;deletes an assignment team&amp;quot; do&lt;br /&gt;
        @assignment = create(:assignment)&lt;br /&gt;
        @a_team = create(:assignment_team)&lt;br /&gt;
&lt;br /&gt;
        expect{ @a_team.delete }.to change(Team, :count).by(-1)&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
    &lt;br /&gt;
    context &amp;quot;with a course team &amp;quot; do&lt;br /&gt;
      it &amp;quot;deletes a course team&amp;quot; do&lt;br /&gt;
        @course = create(:course)&lt;br /&gt;
        @c_team = create(:course_team)&lt;br /&gt;
&lt;br /&gt;
        expect{ @c_team.delete }.to change(Team, :count).by(-1)&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
===Testing List Method===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==References==&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1644._Refactor_and_test_Teams_Controller&amp;diff=103777</id>
		<title>CSC/ECE 517 Fall 2016/E1644. Refactor and test Teams Controller</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1644._Refactor_and_test_Teams_Controller&amp;diff=103777"/>
		<updated>2016-10-29T03:16:56Z</updated>

		<summary type="html">&lt;p&gt;Msardar: /* Testing Create Method */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;'''E1644. Refactor and Test 'Teams_Controller' Controller'''&amp;lt;ref&amp;gt;Project Description document https://google.com&amp;lt;/ref&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This page provides a brief description of the '''Expertiza''' project. The project is aimed at refactoring and testing the 'Teams_Controller' Controller, which contains the methods to create new teams, list the existing teams, create new teams by inheriting existing teams, deleting existing teams and creating multiple teams at once by assigning them random topics. The project entailed, refactoring some part of the controller to improve the readability of code and then creating test cases in [https://en.wikipedia.org/wiki/RSpec RSpec] to verify the methods it possesses. &lt;br /&gt;
&lt;br /&gt;
==Introduction to Expertiza==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a peer review based system which provides incremental learning from the class. This project has been developed together by faculty and students using [http://rubyonrails.org/ Ruby on Rails] framework. Expertiza allows the instructor to create, edit and delete assignments, create new assignment topics, assign them to a particular class or selected students, have students work on teams and then review each other's assignments at the end. For the students, they can signup for topics, form teams, and submit their projects and assignments. &lt;br /&gt;
Students then review the work done by other students and give suggestions to improve. Teams after reviews are allotted scores and they can refer to the peer comments to further improve their work. It also supports submission of different file types for assignments, including the URLs and wiki pages.&lt;br /&gt;
&lt;br /&gt;
== Project Description ==&lt;br /&gt;
'''Teams_Controller''' primarily handles the team creation, deletion and other behaviours. Most of those are called from the instructor’s view. When manual testing is done, most of the methods can be called by clicking the “Create teams” icon from both assignments and courses. &lt;br /&gt;
The following tasks have been performed as per the requirements.&lt;br /&gt;
&lt;br /&gt;
As a part of the project, some GUI's changes had to be made because they did not work the way they should have, some minor issues in the code were fixed and tests were written in '''RSpec''' for the methods delete, create, create teams, list and inherit.&lt;br /&gt;
&lt;br /&gt;
===Create Method===&lt;br /&gt;
The method '''Create''' is called when an instructor tries to create a team manually. This works for both, creating ''assignment teams'' and ''course teams''. Assignment teams are teams made to do a particular assignment together and ''Course Teams'' are teams which are made for the whole course.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to create course teams.&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to create assignment teams.&lt;br /&gt;
&lt;br /&gt;
===Delete Method===&lt;br /&gt;
The method '''Delete''' is called when an instructor tries to delete a team manually. This works for both, deleting ''assignment teams'' and ''course teams''.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to delete course teams.&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to delete assignment teams.&lt;br /&gt;
&lt;br /&gt;
===List Method===&lt;br /&gt;
The method '''List''' lists all the team nodes and the instructor is able to expand each team node to see the user nodes as well.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To check that all teams are being listed in the view.&lt;br /&gt;
&lt;br /&gt;
===Inherit Method===&lt;br /&gt;
The method '''Inherit''' inherits teams from course to assignments, but the “Inherit Teams From Course” option should not display when either 1) we are editing a course object or 2) the current assignment object does not have a course associated with it.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is displayed while creating an assignment team.&lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is not displayed while creating a course team. &lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is not displayed while creating teams for an assignment without a course.&lt;br /&gt;
&lt;br /&gt;
== Refactoring ==&lt;br /&gt;
'''Refactoring'''&amp;lt;ref&amp;gt;Refactoring https://en.wikipedia.org/wiki/Code_refactoring&amp;lt;/ref&amp;gt; is restructuring of code without the need of changing any external behavior. It reduces complexity and improves readability. It also becomes easy to extend the application with respect to different modules and their functionalities.&lt;br /&gt;
Some common techniques to refactor are:&lt;br /&gt;
&lt;br /&gt;
* Moving methods to appropriate modules&lt;br /&gt;
* Breaking methods into more meaningful functionality&lt;br /&gt;
* Creating more generalized code.&lt;br /&gt;
* Renaming methods and variable.&lt;br /&gt;
* Inheritance&lt;br /&gt;
&lt;br /&gt;
As the part of the project, the variable ''@signUps'' in the delete method in the teams_controller was changed to snake case, tp improve readability of code.&lt;br /&gt;
&lt;br /&gt;
== Changes to GUI == &lt;br /&gt;
To fix the view for ''inherit teams'' functionality, changes to the view were made.&lt;br /&gt;
&lt;br /&gt;
Initially, the code was:&lt;br /&gt;
&lt;br /&gt;
  Inherit Teams From Course&lt;br /&gt;
  Use the teams that are currently defined for the course.&lt;br /&gt;
 &amp;lt;%= form_tag :action =&amp;gt; 'inherit' do %&amp;gt;&lt;br /&gt;
   &amp;lt;%= hidden_field_tag 'id', @parent.id %&amp;gt;&lt;br /&gt;
   &amp;lt;%= submit_tag &amp;quot;Inherit&amp;quot; %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Which was changed to:&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;% if not @parent.instance_of?(Course) and not @parent.course.nil? %&amp;gt;&lt;br /&gt;
    Inherit Teams From Course &lt;br /&gt;
    Use the teams that are currently defined for the course.&lt;br /&gt;
   &amp;lt;%= form_tag :action =&amp;gt; 'inherit' do %&amp;gt;&lt;br /&gt;
     &amp;lt;%= hidden_field_tag 'id', @parent.id %&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
    &amp;lt;%= submit_tag &amp;quot;Inherit&amp;quot; %&amp;gt;&lt;br /&gt;
  &amp;lt;% end %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To fix the view, in the ''new.html.erb'' file of teams, we enclose the inherit teams section in an ''if condition'' that checks that the parent of the team is not a Course and it is not an Assignment whose course is nil.&lt;br /&gt;
&lt;br /&gt;
== Testing the Teams_Controller ==&lt;br /&gt;
&lt;br /&gt;
===Testing Inherit Method===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  it 'should display inherit teams while creating an assignment team' do&lt;br /&gt;
    create(:assignment)&lt;br /&gt;
    create(:assignment_node)&lt;br /&gt;
    create(:assignment_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)&lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Assignment'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  it 'should not display inherit teams while creating a course team' do&lt;br /&gt;
    create(:course)&lt;br /&gt;
    create(:course_node)&lt;br /&gt;
    create(:course_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)&lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Course'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_no_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  it 'should not display inherit teams while creating team for an assignment without a course' do&lt;br /&gt;
    create(:assignment_without_course)&lt;br /&gt;
    create(:assignment_without_course_node)&lt;br /&gt;
    create(:assignment_without_course_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)    &lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Assignment'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_no_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
===Testing Create Method===&lt;br /&gt;
&lt;br /&gt;
    describe &amp;quot;POST #create&amp;quot; do&lt;br /&gt;
    context &amp;quot;with an assignment team&amp;quot; do&lt;br /&gt;
      it &amp;quot;increases count by 1&amp;quot; do	&lt;br /&gt;
        expect{create :assignment_team, assignment: @assignment}.to change(Team,:count).by(1)&lt;br /&gt;
      end&lt;br /&gt;
     it &amp;quot;redirects to the list page&amp;quot; do&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
   end&lt;br /&gt;
&lt;br /&gt;
    &lt;br /&gt;
&lt;br /&gt;
    context &amp;quot;with a course team&amp;quot; do&lt;br /&gt;
      it &amp;quot;increases the count by 1&amp;quot; do&lt;br /&gt;
        expect{create :course_team, course: @course}.to change(Team,:count).by(1)&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
===Testing Delete Method===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Testing List Method===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==References==&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1644._Refactor_and_test_Teams_Controller&amp;diff=103776</id>
		<title>CSC/ECE 517 Fall 2016/E1644. Refactor and test Teams Controller</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1644._Refactor_and_test_Teams_Controller&amp;diff=103776"/>
		<updated>2016-10-29T03:15:52Z</updated>

		<summary type="html">&lt;p&gt;Msardar: /* Testing Create Method */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;'''E1644. Refactor and Test 'Teams_Controller' Controller'''&amp;lt;ref&amp;gt;Project Description document https://google.com&amp;lt;/ref&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This page provides a brief description of the '''Expertiza''' project. The project is aimed at refactoring and testing the 'Teams_Controller' Controller, which contains the methods to create new teams, list the existing teams, create new teams by inheriting existing teams, deleting existing teams and creating multiple teams at once by assigning them random topics. The project entailed, refactoring some part of the controller to improve the readability of code and then creating test cases in [https://en.wikipedia.org/wiki/RSpec RSpec] to verify the methods it possesses. &lt;br /&gt;
&lt;br /&gt;
==Introduction to Expertiza==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a peer review based system which provides incremental learning from the class. This project has been developed together by faculty and students using [http://rubyonrails.org/ Ruby on Rails] framework. Expertiza allows the instructor to create, edit and delete assignments, create new assignment topics, assign them to a particular class or selected students, have students work on teams and then review each other's assignments at the end. For the students, they can signup for topics, form teams, and submit their projects and assignments. &lt;br /&gt;
Students then review the work done by other students and give suggestions to improve. Teams after reviews are allotted scores and they can refer to the peer comments to further improve their work. It also supports submission of different file types for assignments, including the URLs and wiki pages.&lt;br /&gt;
&lt;br /&gt;
== Project Description ==&lt;br /&gt;
'''Teams_Controller''' primarily handles the team creation, deletion and other behaviours. Most of those are called from the instructor’s view. When manual testing is done, most of the methods can be called by clicking the “Create teams” icon from both assignments and courses. &lt;br /&gt;
The following tasks have been performed as per the requirements.&lt;br /&gt;
&lt;br /&gt;
As a part of the project, some GUI's changes had to be made because they did not work the way they should have, some minor issues in the code were fixed and tests were written in '''RSpec''' for the methods delete, create, create teams, list and inherit.&lt;br /&gt;
&lt;br /&gt;
===Create Method===&lt;br /&gt;
The method '''Create''' is called when an instructor tries to create a team manually. This works for both, creating ''assignment teams'' and ''course teams''. Assignment teams are teams made to do a particular assignment together and ''Course Teams'' are teams which are made for the whole course.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to create course teams.&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to create assignment teams.&lt;br /&gt;
&lt;br /&gt;
===Delete Method===&lt;br /&gt;
The method '''Delete''' is called when an instructor tries to delete a team manually. This works for both, deleting ''assignment teams'' and ''course teams''.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to delete course teams.&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to delete assignment teams.&lt;br /&gt;
&lt;br /&gt;
===List Method===&lt;br /&gt;
The method '''List''' lists all the team nodes and the instructor is able to expand each team node to see the user nodes as well.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To check that all teams are being listed in the view.&lt;br /&gt;
&lt;br /&gt;
===Inherit Method===&lt;br /&gt;
The method '''Inherit''' inherits teams from course to assignments, but the “Inherit Teams From Course” option should not display when either 1) we are editing a course object or 2) the current assignment object does not have a course associated with it.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is displayed while creating an assignment team.&lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is not displayed while creating a course team. &lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is not displayed while creating teams for an assignment without a course.&lt;br /&gt;
&lt;br /&gt;
== Refactoring ==&lt;br /&gt;
'''Refactoring'''&amp;lt;ref&amp;gt;Refactoring https://en.wikipedia.org/wiki/Code_refactoring&amp;lt;/ref&amp;gt; is restructuring of code without the need of changing any external behavior. It reduces complexity and improves readability. It also becomes easy to extend the application with respect to different modules and their functionalities.&lt;br /&gt;
Some common techniques to refactor are:&lt;br /&gt;
&lt;br /&gt;
* Moving methods to appropriate modules&lt;br /&gt;
* Breaking methods into more meaningful functionality&lt;br /&gt;
* Creating more generalized code.&lt;br /&gt;
* Renaming methods and variable.&lt;br /&gt;
* Inheritance&lt;br /&gt;
&lt;br /&gt;
As the part of the project, the variable ''@signUps'' in the delete method in the teams_controller was changed to snake case, tp improve readability of code.&lt;br /&gt;
&lt;br /&gt;
== Changes to GUI == &lt;br /&gt;
To fix the view for ''inherit teams'' functionality, changes to the view were made.&lt;br /&gt;
&lt;br /&gt;
Initially, the code was:&lt;br /&gt;
&lt;br /&gt;
  Inherit Teams From Course&lt;br /&gt;
  Use the teams that are currently defined for the course.&lt;br /&gt;
 &amp;lt;%= form_tag :action =&amp;gt; 'inherit' do %&amp;gt;&lt;br /&gt;
   &amp;lt;%= hidden_field_tag 'id', @parent.id %&amp;gt;&lt;br /&gt;
   &amp;lt;%= submit_tag &amp;quot;Inherit&amp;quot; %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Which was changed to:&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;% if not @parent.instance_of?(Course) and not @parent.course.nil? %&amp;gt;&lt;br /&gt;
    Inherit Teams From Course &lt;br /&gt;
    Use the teams that are currently defined for the course.&lt;br /&gt;
   &amp;lt;%= form_tag :action =&amp;gt; 'inherit' do %&amp;gt;&lt;br /&gt;
     &amp;lt;%= hidden_field_tag 'id', @parent.id %&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
    &amp;lt;%= submit_tag &amp;quot;Inherit&amp;quot; %&amp;gt;&lt;br /&gt;
  &amp;lt;% end %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To fix the view, in the ''new.html.erb'' file of teams, we enclose the inherit teams section in an ''if condition'' that checks that the parent of the team is not a Course and it is not an Assignment whose course is nil.&lt;br /&gt;
&lt;br /&gt;
== Testing the Teams_Controller ==&lt;br /&gt;
&lt;br /&gt;
===Testing Inherit Method===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  it 'should display inherit teams while creating an assignment team' do&lt;br /&gt;
    create(:assignment)&lt;br /&gt;
    create(:assignment_node)&lt;br /&gt;
    create(:assignment_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)&lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Assignment'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  it 'should not display inherit teams while creating a course team' do&lt;br /&gt;
    create(:course)&lt;br /&gt;
    create(:course_node)&lt;br /&gt;
    create(:course_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)&lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Course'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_no_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  it 'should not display inherit teams while creating team for an assignment without a course' do&lt;br /&gt;
    create(:assignment_without_course)&lt;br /&gt;
    create(:assignment_without_course_node)&lt;br /&gt;
    create(:assignment_without_course_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)    &lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Assignment'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_no_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
===Testing Create Method===&lt;br /&gt;
&lt;br /&gt;
    describe &amp;quot;POST #create&amp;quot; do&lt;br /&gt;
    context &amp;quot;with an assignment team&amp;quot; do&lt;br /&gt;
      it &amp;quot;increases count by 1&amp;quot; do	&lt;br /&gt;
        expect{create :assignment_team, assignment: @assignment}.to change(Team,:count).by(1)&lt;br /&gt;
      end&lt;br /&gt;
     it &amp;quot;redirects to the list page&amp;quot; do&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
    &lt;br /&gt;
&lt;br /&gt;
    context &amp;quot;with a course team&amp;quot; do&lt;br /&gt;
      it &amp;quot;increases the count by 1&amp;quot; do&lt;br /&gt;
        expect{create :course_team, course: @course}.to change(Team,:count).by(1)&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
===Testing Delete Method===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Testing List Method===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==References==&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1644._Refactor_and_test_Teams_Controller&amp;diff=103773</id>
		<title>CSC/ECE 517 Fall 2016/E1644. Refactor and test Teams Controller</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1644._Refactor_and_test_Teams_Controller&amp;diff=103773"/>
		<updated>2016-10-29T03:15:18Z</updated>

		<summary type="html">&lt;p&gt;Msardar: /* Testing Create Method */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;'''E1644. Refactor and Test 'Teams_Controller' Controller'''&amp;lt;ref&amp;gt;Project Description document https://google.com&amp;lt;/ref&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This page provides a brief description of the '''Expertiza''' project. The project is aimed at refactoring and testing the 'Teams_Controller' Controller, which contains the methods to create new teams, list the existing teams, create new teams by inheriting existing teams, deleting existing teams and creating multiple teams at once by assigning them random topics. The project entailed, refactoring some part of the controller to improve the readability of code and then creating test cases in [https://en.wikipedia.org/wiki/RSpec RSpec] to verify the methods it possesses. &lt;br /&gt;
&lt;br /&gt;
==Introduction to Expertiza==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a peer review based system which provides incremental learning from the class. This project has been developed together by faculty and students using [http://rubyonrails.org/ Ruby on Rails] framework. Expertiza allows the instructor to create, edit and delete assignments, create new assignment topics, assign them to a particular class or selected students, have students work on teams and then review each other's assignments at the end. For the students, they can signup for topics, form teams, and submit their projects and assignments. &lt;br /&gt;
Students then review the work done by other students and give suggestions to improve. Teams after reviews are allotted scores and they can refer to the peer comments to further improve their work. It also supports submission of different file types for assignments, including the URLs and wiki pages.&lt;br /&gt;
&lt;br /&gt;
== Project Description ==&lt;br /&gt;
'''Teams_Controller''' primarily handles the team creation, deletion and other behaviours. Most of those are called from the instructor’s view. When manual testing is done, most of the methods can be called by clicking the “Create teams” icon from both assignments and courses. &lt;br /&gt;
The following tasks have been performed as per the requirements.&lt;br /&gt;
&lt;br /&gt;
As a part of the project, some GUI's changes had to be made because they did not work the way they should have, some minor issues in the code were fixed and tests were written in '''RSpec''' for the methods delete, create, create teams, list and inherit.&lt;br /&gt;
&lt;br /&gt;
===Create Method===&lt;br /&gt;
The method '''Create''' is called when an instructor tries to create a team manually. This works for both, creating ''assignment teams'' and ''course teams''. Assignment teams are teams made to do a particular assignment together and ''Course Teams'' are teams which are made for the whole course.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to create course teams.&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to create assignment teams.&lt;br /&gt;
&lt;br /&gt;
===Delete Method===&lt;br /&gt;
The method '''Delete''' is called when an instructor tries to delete a team manually. This works for both, deleting ''assignment teams'' and ''course teams''.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to delete course teams.&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to delete assignment teams.&lt;br /&gt;
&lt;br /&gt;
===List Method===&lt;br /&gt;
The method '''List''' lists all the team nodes and the instructor is able to expand each team node to see the user nodes as well.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To check that all teams are being listed in the view.&lt;br /&gt;
&lt;br /&gt;
===Inherit Method===&lt;br /&gt;
The method '''Inherit''' inherits teams from course to assignments, but the “Inherit Teams From Course” option should not display when either 1) we are editing a course object or 2) the current assignment object does not have a course associated with it.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is displayed while creating an assignment team.&lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is not displayed while creating a course team. &lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is not displayed while creating teams for an assignment without a course.&lt;br /&gt;
&lt;br /&gt;
== Refactoring ==&lt;br /&gt;
'''Refactoring'''&amp;lt;ref&amp;gt;Refactoring https://en.wikipedia.org/wiki/Code_refactoring&amp;lt;/ref&amp;gt; is restructuring of code without the need of changing any external behavior. It reduces complexity and improves readability. It also becomes easy to extend the application with respect to different modules and their functionalities.&lt;br /&gt;
Some common techniques to refactor are:&lt;br /&gt;
&lt;br /&gt;
* Moving methods to appropriate modules&lt;br /&gt;
* Breaking methods into more meaningful functionality&lt;br /&gt;
* Creating more generalized code.&lt;br /&gt;
* Renaming methods and variable.&lt;br /&gt;
* Inheritance&lt;br /&gt;
&lt;br /&gt;
As the part of the project, the variable ''@signUps'' in the delete method in the teams_controller was changed to snake case, tp improve readability of code.&lt;br /&gt;
&lt;br /&gt;
== Changes to GUI == &lt;br /&gt;
To fix the view for ''inherit teams'' functionality, changes to the view were made.&lt;br /&gt;
&lt;br /&gt;
Initially, the code was:&lt;br /&gt;
&lt;br /&gt;
  Inherit Teams From Course&lt;br /&gt;
  Use the teams that are currently defined for the course.&lt;br /&gt;
 &amp;lt;%= form_tag :action =&amp;gt; 'inherit' do %&amp;gt;&lt;br /&gt;
   &amp;lt;%= hidden_field_tag 'id', @parent.id %&amp;gt;&lt;br /&gt;
   &amp;lt;%= submit_tag &amp;quot;Inherit&amp;quot; %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Which was changed to:&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;% if not @parent.instance_of?(Course) and not @parent.course.nil? %&amp;gt;&lt;br /&gt;
    Inherit Teams From Course &lt;br /&gt;
    Use the teams that are currently defined for the course.&lt;br /&gt;
   &amp;lt;%= form_tag :action =&amp;gt; 'inherit' do %&amp;gt;&lt;br /&gt;
     &amp;lt;%= hidden_field_tag 'id', @parent.id %&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
    &amp;lt;%= submit_tag &amp;quot;Inherit&amp;quot; %&amp;gt;&lt;br /&gt;
  &amp;lt;% end %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To fix the view, in the ''new.html.erb'' file of teams, we enclose the inherit teams section in an ''if condition'' that checks that the parent of the team is not a Course and it is not an Assignment whose course is nil.&lt;br /&gt;
&lt;br /&gt;
== Testing the Teams_Controller ==&lt;br /&gt;
&lt;br /&gt;
===Testing Inherit Method===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  it 'should display inherit teams while creating an assignment team' do&lt;br /&gt;
    create(:assignment)&lt;br /&gt;
    create(:assignment_node)&lt;br /&gt;
    create(:assignment_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)&lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Assignment'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  it 'should not display inherit teams while creating a course team' do&lt;br /&gt;
    create(:course)&lt;br /&gt;
    create(:course_node)&lt;br /&gt;
    create(:course_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)&lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Course'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_no_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  it 'should not display inherit teams while creating team for an assignment without a course' do&lt;br /&gt;
    create(:assignment_without_course)&lt;br /&gt;
    create(:assignment_without_course_node)&lt;br /&gt;
    create(:assignment_without_course_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)    &lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Assignment'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_no_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
===Testing Create Method===&lt;br /&gt;
&lt;br /&gt;
    describe &amp;quot;POST #create&amp;quot; do&lt;br /&gt;
    context &amp;quot;with an assignment team&amp;quot; do&lt;br /&gt;
      it &amp;quot;increases count by 1&amp;quot; do	&lt;br /&gt;
        expect{create :assignment_team, assignment: @assignment}.to change(Team,:count).by(1)&lt;br /&gt;
      end&lt;br /&gt;
     it &amp;quot;redirects to the list page&amp;quot; do&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
    context &amp;quot;with a course team&amp;quot; do&lt;br /&gt;
      it &amp;quot;increases the count by 1&amp;quot; do&lt;br /&gt;
        expect{create :course_team, course: @course}.to change(Team,:count).by(1)&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
===Testing Delete Method===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Testing List Method===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==References==&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1644._Refactor_and_test_Teams_Controller&amp;diff=103771</id>
		<title>CSC/ECE 517 Fall 2016/E1644. Refactor and test Teams Controller</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1644._Refactor_and_test_Teams_Controller&amp;diff=103771"/>
		<updated>2016-10-29T03:14:42Z</updated>

		<summary type="html">&lt;p&gt;Msardar: /* Testing Create Method */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;'''E1644. Refactor and Test 'Teams_Controller' Controller'''&amp;lt;ref&amp;gt;Project Description document https://google.com&amp;lt;/ref&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This page provides a brief description of the '''Expertiza''' project. The project is aimed at refactoring and testing the 'Teams_Controller' Controller, which contains the methods to create new teams, list the existing teams, create new teams by inheriting existing teams, deleting existing teams and creating multiple teams at once by assigning them random topics. The project entailed, refactoring some part of the controller to improve the readability of code and then creating test cases in [https://en.wikipedia.org/wiki/RSpec RSpec] to verify the methods it possesses. &lt;br /&gt;
&lt;br /&gt;
==Introduction to Expertiza==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a peer review based system which provides incremental learning from the class. This project has been developed together by faculty and students using [http://rubyonrails.org/ Ruby on Rails] framework. Expertiza allows the instructor to create, edit and delete assignments, create new assignment topics, assign them to a particular class or selected students, have students work on teams and then review each other's assignments at the end. For the students, they can signup for topics, form teams, and submit their projects and assignments. &lt;br /&gt;
Students then review the work done by other students and give suggestions to improve. Teams after reviews are allotted scores and they can refer to the peer comments to further improve their work. It also supports submission of different file types for assignments, including the URLs and wiki pages.&lt;br /&gt;
&lt;br /&gt;
== Project Description ==&lt;br /&gt;
'''Teams_Controller''' primarily handles the team creation, deletion and other behaviours. Most of those are called from the instructor’s view. When manual testing is done, most of the methods can be called by clicking the “Create teams” icon from both assignments and courses. &lt;br /&gt;
The following tasks have been performed as per the requirements.&lt;br /&gt;
&lt;br /&gt;
As a part of the project, some GUI's changes had to be made because they did not work the way they should have, some minor issues in the code were fixed and tests were written in '''RSpec''' for the methods delete, create, create teams, list and inherit.&lt;br /&gt;
&lt;br /&gt;
===Create Method===&lt;br /&gt;
The method '''Create''' is called when an instructor tries to create a team manually. This works for both, creating ''assignment teams'' and ''course teams''. Assignment teams are teams made to do a particular assignment together and ''Course Teams'' are teams which are made for the whole course.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to create course teams.&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to create assignment teams.&lt;br /&gt;
&lt;br /&gt;
===Delete Method===&lt;br /&gt;
The method '''Delete''' is called when an instructor tries to delete a team manually. This works for both, deleting ''assignment teams'' and ''course teams''.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to delete course teams.&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to delete assignment teams.&lt;br /&gt;
&lt;br /&gt;
===List Method===&lt;br /&gt;
The method '''List''' lists all the team nodes and the instructor is able to expand each team node to see the user nodes as well.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To check that all teams are being listed in the view.&lt;br /&gt;
&lt;br /&gt;
===Inherit Method===&lt;br /&gt;
The method '''Inherit''' inherits teams from course to assignments, but the “Inherit Teams From Course” option should not display when either 1) we are editing a course object or 2) the current assignment object does not have a course associated with it.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is displayed while creating an assignment team.&lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is not displayed while creating a course team. &lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is not displayed while creating teams for an assignment without a course.&lt;br /&gt;
&lt;br /&gt;
== Refactoring ==&lt;br /&gt;
'''Refactoring'''&amp;lt;ref&amp;gt;Refactoring https://en.wikipedia.org/wiki/Code_refactoring&amp;lt;/ref&amp;gt; is restructuring of code without the need of changing any external behavior. It reduces complexity and improves readability. It also becomes easy to extend the application with respect to different modules and their functionalities.&lt;br /&gt;
Some common techniques to refactor are:&lt;br /&gt;
&lt;br /&gt;
* Moving methods to appropriate modules&lt;br /&gt;
* Breaking methods into more meaningful functionality&lt;br /&gt;
* Creating more generalized code.&lt;br /&gt;
* Renaming methods and variable.&lt;br /&gt;
* Inheritance&lt;br /&gt;
&lt;br /&gt;
As the part of the project, the variable ''@signUps'' in the delete method in the teams_controller was changed to snake case, tp improve readability of code.&lt;br /&gt;
&lt;br /&gt;
== Changes to GUI == &lt;br /&gt;
To fix the view for ''inherit teams'' functionality, changes to the view were made.&lt;br /&gt;
&lt;br /&gt;
Initially, the code was:&lt;br /&gt;
&lt;br /&gt;
  Inherit Teams From Course&lt;br /&gt;
  Use the teams that are currently defined for the course.&lt;br /&gt;
 &amp;lt;%= form_tag :action =&amp;gt; 'inherit' do %&amp;gt;&lt;br /&gt;
   &amp;lt;%= hidden_field_tag 'id', @parent.id %&amp;gt;&lt;br /&gt;
   &amp;lt;%= submit_tag &amp;quot;Inherit&amp;quot; %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Which was changed to:&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;% if not @parent.instance_of?(Course) and not @parent.course.nil? %&amp;gt;&lt;br /&gt;
    Inherit Teams From Course &lt;br /&gt;
    Use the teams that are currently defined for the course.&lt;br /&gt;
   &amp;lt;%= form_tag :action =&amp;gt; 'inherit' do %&amp;gt;&lt;br /&gt;
     &amp;lt;%= hidden_field_tag 'id', @parent.id %&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
    &amp;lt;%= submit_tag &amp;quot;Inherit&amp;quot; %&amp;gt;&lt;br /&gt;
  &amp;lt;% end %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To fix the view, in the ''new.html.erb'' file of teams, we enclose the inherit teams section in an ''if condition'' that checks that the parent of the team is not a Course and it is not an Assignment whose course is nil.&lt;br /&gt;
&lt;br /&gt;
== Testing the Teams_Controller ==&lt;br /&gt;
&lt;br /&gt;
===Testing Inherit Method===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  it 'should display inherit teams while creating an assignment team' do&lt;br /&gt;
    create(:assignment)&lt;br /&gt;
    create(:assignment_node)&lt;br /&gt;
    create(:assignment_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)&lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Assignment'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  it 'should not display inherit teams while creating a course team' do&lt;br /&gt;
    create(:course)&lt;br /&gt;
    create(:course_node)&lt;br /&gt;
    create(:course_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)&lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Course'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_no_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  it 'should not display inherit teams while creating team for an assignment without a course' do&lt;br /&gt;
    create(:assignment_without_course)&lt;br /&gt;
    create(:assignment_without_course_node)&lt;br /&gt;
    create(:assignment_without_course_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)    &lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Assignment'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_no_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
===Testing Create Method===&lt;br /&gt;
&lt;br /&gt;
    describe &amp;quot;POST #create&amp;quot; do&lt;br /&gt;
    context &amp;quot;with an assignment team&amp;quot; do&lt;br /&gt;
      it &amp;quot;increases count by 1&amp;quot; do	&lt;br /&gt;
        expect{create :assignment_team, assignment: @assignment}.to change(Team,:count).by(1)&lt;br /&gt;
      end&lt;br /&gt;
&lt;br /&gt;
      it &amp;quot;redirects to the list page&amp;quot; do&lt;br /&gt;
      end&lt;br /&gt;
    end&lt;br /&gt;
    &lt;br /&gt;
    context &amp;quot;with a course team&amp;quot; do&lt;br /&gt;
      it &amp;quot;increases the count by 1&amp;quot; do&lt;br /&gt;
        expect{create :course_team, course: @course}.to change(Team,:count).by(1)&lt;br /&gt;
      end&lt;br /&gt;
&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
===Testing Delete Method===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Testing List Method===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==References==&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1644._Refactor_and_test_Teams_Controller&amp;diff=103693</id>
		<title>CSC/ECE 517 Fall 2016/E1644. Refactor and test Teams Controller</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Fall_2016/E1644._Refactor_and_test_Teams_Controller&amp;diff=103693"/>
		<updated>2016-10-29T02:38:20Z</updated>

		<summary type="html">&lt;p&gt;Msardar: /* Refactoring */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;'''E1644. Refactor and Test 'Teams_Controller' Controller'''&amp;lt;ref&amp;gt;Project Description document https://google.com&amp;lt;/ref&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This page provides a brief description of the '''Expertiza''' project. The project is aimed at refactoring and testing the 'Teams_Controller' Controller, which contains the methods to create new teams, list the existing teams, create new teams by inheriting existing teams, deleting existing teams and creating multiple teams at once by assigning them random topics. The project entailed, refactoring some part of the controller to improve the readability of code and then creating test cases in [https://en.wikipedia.org/wiki/RSpec RSpec] to verify the methods it possesses. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Introduction to Expertiza==&lt;br /&gt;
[http://expertiza.ncsu.edu/ Expertiza] is a peer review based system which provides incremental learning from the class. This project has been developed together by faculty and students using [http://rubyonrails.org/ Ruby on Rails] framework. Expertiza allows the instructor to create, edit and delete assignments, create new assignment topics, assign them to a particular class or selected students, have students work on teams and then review each other's assignments at the end. For the students, they can signup for topics, form teams, and submit their projects and assignments. &lt;br /&gt;
Students then review the work done by other students and give suggestions to improve. Teams after reviews are allotted scores and they can refer to the peer comments to further improve their work. It also supports submission of different file types for assignments, including the URLs and wiki pages.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Project Description ==&lt;br /&gt;
'''Teams_Controller''' primarily handles the team creation, deletion and other behaviours. Most of those are called from the instructor’s view. When manual testing is done, most of the methods can be called by clicking the “Create teams” icon from both assignments and courses. &lt;br /&gt;
The following tasks have been performed as per the requirements.&lt;br /&gt;
&lt;br /&gt;
As a part of the project, some GUI's changes had to be made because they did not work the way they should have, some minor issues in the code were fixed and tests were written in '''RSpec''' for the methods delete, create, create teams, list and inherit.&lt;br /&gt;
&lt;br /&gt;
===Create Method===&lt;br /&gt;
The method '''Create''' is called when an instructor tries to create a team manually. This works for both, creating ''assignment teams'' and ''course teams''. Assignment teams are teams made to do a particular assignment together and ''Course Teams'' are teams which are made for the whole course.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to create course teams.&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to create assignment teams.&lt;br /&gt;
&lt;br /&gt;
===Delete Method===&lt;br /&gt;
The method '''Delete''' is called when an instructor tries to delete a team manually. This works for both, deleting ''assignment teams'' and ''course teams''.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to delete course teams.&lt;br /&gt;
&lt;br /&gt;
* To verify that the Instructor is able to delete assignment teams.&lt;br /&gt;
&lt;br /&gt;
===List Method===&lt;br /&gt;
The method '''List''' lists all the team nodes and the instructor is able to expand each team node to see the user nodes as well.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To check that all teams are being listed in the view.&lt;br /&gt;
&lt;br /&gt;
===Inherit Method===&lt;br /&gt;
The method '''Inherit''' inherits teams from course to assignments, but the “Inherit Teams From Course” option should not display when either 1) we are editing a course object or 2) the current assignment object does not have a course associated with it.&lt;br /&gt;
&lt;br /&gt;
Following Test Cases were written and executed in RSpec to test this method:&lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is displayed while creating an assignment team.&lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is not displayed while creating a course team. &lt;br /&gt;
&lt;br /&gt;
* To check that ''inherit teams'' is not displayed while creating teams for an assignment without a course.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Refactoring ==&lt;br /&gt;
'''Refactoring'''&amp;lt;ref&amp;gt;Refactoring https://en.wikipedia.org/wiki/Code_refactoring&amp;lt;/ref&amp;gt; is restructuring of code without the need of changing any external behavior. It reduces complexity and improves readability. It also becomes easy to extend the application with respect to different modules and their functionalities.&lt;br /&gt;
Some common techniques to refactor are:&lt;br /&gt;
&lt;br /&gt;
* Moving methods to appropriate modules&lt;br /&gt;
* Breaking methods into more meaningful functionality&lt;br /&gt;
* Creating more generalized code.&lt;br /&gt;
* Renaming methods and variable.&lt;br /&gt;
* Inheritance&lt;br /&gt;
&lt;br /&gt;
As the part of the project, the variable ''@signUps'' in the delete method in the teams_controller was changed to snake case, tp improve readability of code.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Changes in UI, to fix view for inherit team&lt;br /&gt;
In the new.html.erb file of teams, we enclose the inherit teams section in an if condition that checks that the parent of the team is not a Course and it is not an Assignment whose course is nil.&lt;br /&gt;
&lt;br /&gt;
== Testing the Teams_Controller ==&lt;br /&gt;
&lt;br /&gt;
===Testing Inherit Method===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  it 'should display inherit teams while creating an assignment team' do&lt;br /&gt;
    create(:assignment)&lt;br /&gt;
    create(:assignment_node)&lt;br /&gt;
    create(:assignment_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)&lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Assignment'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  it 'should not display inherit teams while creating a course team' do&lt;br /&gt;
    create(:course)&lt;br /&gt;
    create(:course_node)&lt;br /&gt;
    create(:course_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)&lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Course'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_no_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  it 'should not display inherit teams while creating team for an assignment without a course' do&lt;br /&gt;
    create(:assignment_without_course)&lt;br /&gt;
    create(:assignment_without_course_node)&lt;br /&gt;
    create(:assignment_without_course_team)&lt;br /&gt;
    login_as(&amp;quot;instructor6&amp;quot;)    &lt;br /&gt;
    visit '/teams/list?id=1&amp;amp;type=Assignment'&lt;br /&gt;
    click_link 'Create Team'&lt;br /&gt;
    expect(page).to have_no_content('Inherit Teams From Course')&lt;br /&gt;
  end&lt;br /&gt;
&lt;br /&gt;
===Testing Create Method===&lt;br /&gt;
&lt;br /&gt;
===Testing Delete Method===&lt;br /&gt;
&lt;br /&gt;
===Testing Inherit Method===&lt;br /&gt;
&lt;br /&gt;
===Testing List Method===&lt;/div&gt;</summary>
		<author><name>Msardar</name></author>
	</entry>
</feed>