Fixed issue 656, Grace periods not calculated correctly on the basis on the repo times #759

Merged
merged 10 commits into from Jun 25, 2012

Conversation

Projects
None yet
3 participants
@mikeing2001
Contributor

mikeing2001 commented Jun 20, 2012

Fix for issue 656. Previously, when calcuating grace days, we were only checking last submittion. However, that does not provide a correct calcuation as we could have submitted files for another assignment and that would cause MarkUs to think we are using a grace day. The Fix is to check to see if the revision has submitted any files from the assignment and only submittions that contain files for the assignment do we used to calcuate grace days. This fix is for both memory_repository and subversion_repository.

This review is a continuation of Review #1231 on Review Board: http://review.markusproject.org/r/1231/

lib/repo/memory_repository.rb
if @timestamps_revisions.empty?
raise "No revisions, so no timestamps."
end
timestamps_list = []
+ timestamps_list1 = []

This comment has been minimized.

@jerboaa

jerboaa Jun 21, 2012

Member

Just a nit, but I'm sure there's a better name for this variable. timestammps_list1 is a bit constructed :)

@jerboaa

jerboaa Jun 21, 2012

Member

Just a nit, but I'm sure there's a better name for this variable. timestammps_list1 is a bit constructed :)

+ end
+ end
+
+ # Regression test for issue 656. The issue is when submitting files for an assignment before the grace period

This comment has been minimized.

@jerboaa

jerboaa Jun 21, 2012

Member

Nice! Thanks!

@jerboaa

jerboaa Jun 21, 2012

Member

Nice! Thanks!

mikeing2001 added some commits Jun 22, 2012

Fix for issue 656, rename variable in memory_repository as well as fi…
…x issue with subversion_repository when assignment is late and there is no more grace days available
@mikeing2001

This comment has been minimized.

Show comment
Hide comment
@mikeing2001

mikeing2001 Jun 22, 2012

Contributor

Manual Testing Done

  1. Assignment Submitted on time
  2. Assignment Submitted on time with next assignment submitted before previous assignment is due
  3. Assignment Submitted late
  4. Assignment Submitted late and no grace days left.

Plus ran both unit testing and functional testing

Contributor

mikeing2001 commented Jun 22, 2012

Manual Testing Done

  1. Assignment Submitted on time
  2. Assignment Submitted on time with next assignment submitted before previous assignment is due
  3. Assignment Submitted late
  4. Assignment Submitted late and no grace days left.

Plus ran both unit testing and functional testing

@jerboaa

This comment has been minimized.

Show comment
Hide comment
@jerboaa

jerboaa Jun 22, 2012

Member

Looks good to me. Feel free to merge :) Benjamin?

Member

jerboaa commented Jun 22, 2012

Looks good to me. Feel free to merge :) Benjamin?

benjaminvialle added a commit that referenced this pull request Jun 25, 2012

Merge pull request #759 from mikeing2001/issue-656
Fixed issue 656, Grace periods not calculated correctly on the basis on the repo times
Closes #656

@benjaminvialle benjaminvialle merged commit 5cfe934 into MarkUsProject:master Jun 25, 2012

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment