-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
300 fullstack refactor rubicitems to be dynamic #383
300 fullstack refactor rubicitems to be dynamic #383
Conversation
@frozenfrank These changes may be helpful with #239 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks like an overall major improvement to the autograder. I've left comments about potential improvements, but none of them are showstoppers. Thanks for making these helpful adjustments!
@@ -47,7 +48,7 @@ private <T> Set<T> allPreviousPhases(PhaseFunction<T> func) throws GradingExcept | |||
Phase previous = gradingContext.phase(); | |||
while ((previous = PhaseUtils.getPreviousPhase(previous)) != null) { | |||
RubricConfig rubricConfig = DaoService.getRubricConfigDao().getRubricConfig(previous); | |||
if(rubricConfig.passoffTests() != null) { | |||
if(rubricConfig.items().get(Rubric.RubricType.PASSOFF_TESTS) != null) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Note: RubricConfig
is still a class. We could provide helpful methods to preserve the existing method calls, and avoid all these code updates.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are only two instances where we get this with a specific type in mind rather than a dynamic variable type. I would think that adding extra methods would add extra clutter for not that much added benefit. Do you disagree?
Should be fairly self explanatory. Converted the three RubricItem's to an EnumMap, so we can add things to the enum and it becomes a new item