Skip to content
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

Fix bug with quiz next button skipping questions #2312

Merged
merged 2 commits into from
Jul 2, 2023

Conversation

lesterong
Copy link
Contributor

@lesterong lesterong commented Jun 25, 2023

What is the purpose of this pull request?

  • Documentation update
  • Bug fix
  • Feature addition or enhancement
  • Code maintenance
  • DevOps
  • Improve developer experience
  • Others, please explain:

Overview of changes:

Only allow the click event on the Next button in Quiz to be triggered once. Resolves #2188.

Anything you'd like to highlight/discuss:

NIL

Testing instructions:

NIL

Proposed commit message: (wrap lines at 72 characters)

Fix Quiz next button skipping questions


Checklist: ☑️

  • Updated the documentation for feature additions and enhancements
  • Added tests for bug fixes or features
  • Linked all related issues
  • No unrelated changes

@yucheng11122017
Copy link
Contributor

Hi @lesterong thanks very much for the work on this PR!
Gentle reminder not to delete the PR template when creating a PR :) You can just fill in nil for things if there's nothing to add and so on.
Also, could you try to add unit tests for this PR? Thanks!

@lesterong
Copy link
Contributor Author

Hi @lesterong thanks very much for the work on this PR! Gentle reminder not to delete the PR template when creating a PR :) You can just fill in nil for things if there's nothing to add and so on. Also, could you try to add unit tests for this PR? Thanks!

@yucheng11122017, noted on that! I have edited my comment with the full template. Also, may I clarify what unit tests to add? It seems like the tests for the Quiz component were skipped in an earlier pull request #2244.

@itsyme
Copy link
Contributor

itsyme commented Jun 26, 2023

Hi @lesterong thanks very much for the work on this PR! Gentle reminder not to delete the PR template when creating a PR :) You can just fill in nil for things if there's nothing to add and so on. Also, could you try to add unit tests for this PR? Thanks!

@yucheng11122017, noted on that! I have edited my comment with the full template. Also, may I clarify what unit tests to add? It seems like the tests for the Quiz component were skipped in an earlier pull request #2244.

hi @lesterong! the tests were disabled due to some unexpected behaviour with setTimeout being used in the tests causing CI to fail sometimes. perhaps you could test the fix locally but skip it when you commit so that we can unskip them when we solve #2238

@tlylt tlylt requested a review from itsyme July 1, 2023 13:54
@tlylt
Copy link
Contributor

tlylt commented Jul 1, 2023

Checked on https://deploy-preview-2312--markbind-master.netlify.app/userguide/components/others#quizzes and the behavior seems to be corrected 👍

Copy link
Contributor

@yucheng11122017 yucheng11122017 left a comment

Choose a reason for hiding this comment

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

LGTM! Thanks @lesterong

@itsyme
Copy link
Contributor

itsyme commented Jul 2, 2023

LGTM! I've checked out the tests as well and it seems to work as intended. Thanks @lesterong!

@itsyme itsyme added this to the v4.1.1 milestone Jul 2, 2023
@itsyme itsyme merged commit 5abce7a into MarkBind:master Jul 2, 2023
5 checks passed
itsyme added a commit that referenced this pull request Jul 2, 2023
@itsyme
Copy link
Contributor

itsyme commented Jul 2, 2023

@all-contributors please add lesterong for code

@allcontributors
Copy link
Contributor

@itsyme

I've put up a pull request to add @lesterong! 🎉

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.

Quiz skipping questions when pressing next multiple times
4 participants