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

feat: implemented restricted countries functionalities #1194

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

sundasnoreen12
Copy link
Contributor

@sundasnoreen12 sundasnoreen12 commented Feb 19, 2025

Description

We are introducing a feature that allows platform administrators to restrict users from selecting one or more countries in Account MFEs.

How Has This Been Tested?

We retrieved the list of restricted countries by calling the following API:

👉 https://courses.edx.org/user_api/v1/account/registration/

At the same time, we obtained the translated country names using the i18n-iso-countries package.

Once both datasets were available, we filtered out the restricted countries from the translated list and displayed the updated country list in the UI.

Merge Checklist

  • If your update includes visual changes, have they been reviewed by a designer? Send them a link to the Sandbox, if applicable.
  • Is there adequate test coverage for your changes?

Post-merge Checklist

  • Deploy the changes to prod after verifying on stage or ask @openedx/2u-infinity to do it.
  • 🎉 🙌 Celebrate! Thanks for your contribution.

Copy link

codecov bot commented Feb 19, 2025

Codecov Report

Attention: Patch coverage is 50.00000% with 15 lines in your changes missing coverage. Please review.

Project coverage is 58.39%. Comparing base (9eda5e5) to head (5a9ae87).

Files with missing lines Patch % Lines
src/account-settings/data/service.js 0.00% 10 Missing and 1 partial ⚠️
src/account-settings/AccountSettingsPage.jsx 75.00% 4 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1194      +/-   ##
==========================================
- Coverage   58.53%   58.39%   -0.15%     
==========================================
  Files         117      117              
  Lines        2320     2348      +28     
  Branches      639      648       +9     
==========================================
+ Hits         1358     1371      +13     
- Misses        901      915      +14     
- Partials       61       62       +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@sundasnoreen12 sundasnoreen12 force-pushed the sundas/INF-1779 branch 2 times, most recently from 66cf09b to b9a9717 Compare February 19, 2025 11:37
@awais-ansari
Copy link
Contributor

Please add a test case to improve test coverage.

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.

3 participants