-
Notifications
You must be signed in to change notification settings - Fork 351
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
Remove scoreInput
#1973
Remove scoreInput
#1973
Conversation
npm Snapshot: PublishedGood news!! We've packaged up the latest commit from this PR (4958a63) and published it to npm. You Example: yarn add @khanacademy/perseus@PR1973 If you are working in Khan Academy's webapp, you can run: ./dev/tools/bump_perseus_version.sh -t PR1973 |
Size Change: -410 B (-0.03%) Total Size: 1.27 MB
ℹ️ View Unchanged
|
@@ -118,31 +118,6 @@ describe("server item renderer", () => { | |||
expect(screen.getByRole("textbox")).toBeVisible(); | |||
}); | |||
|
|||
it("should be invalid if no input provided", async () => { |
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.
I don't like deleting tests, but these seem to be specifically focused on testing SIR's ability to score.
@@ -165,9 +165,6 @@ function scoreExpression( | |||
// We matched a graded answer form, so we can now tell the user | |||
// whether their input was correct or incorrect, and hand out | |||
// points accordingly | |||
// TODO(eater): Seems silly to translate result to this |
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.
idk, I think we're past the point of doing anything about this since this is from the Eater era.
## Summary: Remove `guessAndScore` from Renderer. This hasn't been used in learner-facing logic for a little bit now. The bulk of this PR is updating internal usage - tools for testing exercise correctness were using this (specifically in Cypress and our custom matchers for Jest); so most of the work was porting tests to use `scorePerseusItem` instead. ## Test plan: From a learner's perspective, this is dead code. So while this is a major API change, it's mostly removing dead code and updating tests. Tests should continue to run successfully. Author: handeyeco Reviewers: handeyeco, Myranae, jeremywiebe Required Reviewers: Approved By: Myranae, jeremywiebe Checks: ✅ Publish npm snapshot (ubuntu-latest, 20.x), ✅ Cypress (ubuntu-latest, 20.x), ✅ Check for .changeset entries for all changed files (ubuntu-latest, 20.x), ✅ Check builds for changes in size (ubuntu-latest, 20.x), ✅ Lint, Typecheck, Format, and Test (ubuntu-latest, 20.x), ⏹️ [cancelled] Publish npm snapshot (ubuntu-latest, 20.x), ⏹️ [cancelled] Check for .changeset entries for all changed files (ubuntu-latest, 20.x), ⏹️ [cancelled] Check builds for changes in size (ubuntu-latest, 20.x), ⏹️ [cancelled] Cypress (ubuntu-latest, 20.x), ⏹️ [cancelled] Lint, Typecheck, Format, and Test (ubuntu-latest, 20.x), ✅ Publish npm snapshot (ubuntu-latest, 20.x), ✅ Lint, Typecheck, Format, and Test (ubuntu-latest, 20.x), ✅ Check builds for changes in size (ubuntu-latest, 20.x), ✅ Cypress (ubuntu-latest, 20.x), ✅ Check for .changeset entries for all changed files (ubuntu-latest, 20.x), ✅ Publish Storybook to Chromatic (ubuntu-latest, 20.x) Pull Request URL: #1974
Summary:
Remove
scoreInput
from ServerItemRenderer. This was marked as deprecated and uses of it in Webapp have been removed in favor ofscorePerseusItem
.Test plan:
This was an external-facing API and usage was already removed. At this point it's just dead code, so I'm not sure what would need to be tested.