CSC/ECE 517 Fall 2015/oss E1574 BKS: Difference between revisions

From Expertiza_Wiki
Jump to navigation Jump to search
No edit summary
Line 3: Line 3:
==Introduction==
==Introduction==
Our contribution in this project is to write feature test for assignment submission by student. The test would mock steps taken by the student to manually submit the assignment.
Our contribution in this project is to write feature test for assignment submission by student. The test would mock steps taken by the student to manually submit the assignment.
===Problem Statement===


===Assumptions===
===Assumptions===
Line 19: Line 21:
# Paste the link or browse the file containing your work
# Paste the link or browse the file containing your work
# Click on "Upload Link" or "Upload File" to submit deliverable
# Click on "Upload Link" or "Upload File" to submit deliverable
 
== Creating the Tests==
===Gems involved===
====Rspec====
====Capybara====
 
===Feature test scenarios covered===
===Feature test scenarios covered===
Scenarios
Scenarios
Line 29: Line 36:
# scenario 'submitting file to ongoing assignment'
# scenario 'submitting file to ongoing assignment'


==Gems involved==
===Code written for feature test===  
===Rspec===
====assignment_creation.rb===
===Capybara===
====student_assignment_submission.rb===


===Files changed===
===Code written for feature test===


===How to run the feature test===
==Running  the tests==


===How to review the feature test===
Steps
Steps
# Git fork
# Git fork
Line 47: Line 49:
# use command rspec spec/features/student_assignment_submission_spec.rb
# use command rspec spec/features/student_assignment_submission_spec.rb


===Video Tutorial===
==Test Results===


===Images===
==Project Resources==
GitHub Link
Video Tutorial
Images


== References ==
== References ==

Revision as of 02:14, 1 November 2015

Expertiza is a web application where students can submit and peer-review learning objects (articles, code, web sites, etc). It is used in select courses at NC State and by professors at several other colleges and universities. <ref>Template:Expertiza GitHub Page</ref>

Introduction

Our contribution in this project is to write feature test for assignment submission by student. The test would mock steps taken by the student to manually submit the assignment.

Problem Statement

Assumptions

To implement each scenario in the test, the following assumptions are taken:

  1. The feature test will use the development environment. In particular, it will use the expertiza_development database.
  2. A student entry is assumed to be present in the database. The credentials for this student is student13 as username and password as password.
  3. An instructor entry is also assumed to be present in the database. Its credentials are username: instructor6 and password: password.
  4. A simple assignment is created wherein there are no teams and topics.
  5. It requires user to first run the ["assignment_creation.rb"], so that the student becomes eligible to submit his/her work.

Steps for manual submission

Before analyzing code, one must make themselves familiar with the steps involved in assignment submission on Expertiza. These steps are:

  1. Login with valid username and password
  2. Click on an assignment to submit
  3. Click on "Your Work"
  4. Paste the link or browse the file containing your work
  5. Click on "Upload Link" or "Upload File" to submit deliverable

Creating the Tests

Gems involved

Rspec

Capybara

Feature test scenarios covered

Scenarios

  1. scenario 'student with valid credentials'
  2. scenario 'no assignment available to submit'
  3. scenario 'submitting link for finished assignment'
  4. scenario 'submitting file for finished assignment'
  5. scenario 'submitting link to ongoing assignment'
  6. scenario 'submitting file to ongoing assignment'

Code written for feature test

=assignment_creation.rb

=student_assignment_submission.rb

Running the tests

Steps

  1. Git fork
  2. bundle install
  3. db:migrate
  4. use command rspec spec/features/student_assignment_submission_spec.rb

Test Results=

Project Resources

GitHub Link Video Tutorial Images

References

External links