Skip to content

remove run button#33

Merged
admclamb merged 2 commits into
mainfrom
admclamb/remove-run-button
May 25, 2026
Merged

remove run button#33
admclamb merged 2 commits into
mainfrom
admclamb/remove-run-button

Conversation

@admclamb
Copy link
Copy Markdown
Collaborator

No description provided.

Copilot AI review requested due to automatic review settings May 25, 2026 21:14
@vercel
Copy link
Copy Markdown

vercel Bot commented May 25, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
web-aw-prod-01 Ready Ready Preview, Comment May 25, 2026 9:26pm
web-aw-scrum-01 Ready Ready Preview, Comment May 25, 2026 9:26pm

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR removes the “Run” action from the Problem page’s action bar, leaving only “Submit” and “View Submissions”, and updates the associated unit tests accordingly.

Changes:

  • Removed the Run button and its handler from ProblemActions.
  • Updated ProblemActions tests to stop asserting Run-related behavior and to reflect the new UI structure.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.

File Description
src/features/problem/problem-actions/problem-actions.tsx Removes Run UI/handler; leaves Submit + View Submissions.
src/features/problem/problem-actions/problem-actions.test.tsx Removes Run-related test cases and updates list-item/lock-icon assertions.
Comments suppressed due to low confidence (1)

src/features/problem/problem-actions/problem-actions.test.tsx:141

  • In this test, createSubmission (used by useCreateSubmission) returns a string, but the mock resolves to an object ({ submissionId: "123" }). Also, the component calls setActiveSubmissionId(id) after the mutation resolves, so the mocked store state needs to include a setActiveSubmissionId function (and ideally assert it was called with the returned string) to avoid runtime errors during the click.
  it("calls submitSubmissionMutation when Submit button is clicked", async () => {
    setupMocks();
    mockSubmitMutateAsync.mockResolvedValue({ submissionId: "123" });
    const user = userEvent.setup();

Comment on lines 30 to 32
const runSubmissionMutation = useRunSubmission();
const submitSubmissionMutation = useCreateSubmission();

Comment on lines 55 to 57
<li>
<Button
className="w-24"
@admclamb admclamb merged commit ed19c3f into main May 25, 2026
2 of 5 checks passed
@admclamb admclamb deleted the admclamb/remove-run-button branch May 25, 2026 21:23
@sonarqubecloud
Copy link
Copy Markdown

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants