Skip to content

test(frontend): add spec for RegistrationRequestModalComponent#5583

Open
EmilySun621 wants to merge 1 commit into
apache:mainfrom
EmilySun621:test/registration-request-modal
Open

test(frontend): add spec for RegistrationRequestModalComponent#5583
EmilySun621 wants to merge 1 commit into
apache:mainfrom
EmilySun621:test/registration-request-modal

Conversation

@EmilySun621

@EmilySun621 EmilySun621 commented Jun 9, 2026

Copy link
Copy Markdown
Contributor

Covers constructor hydration from NZ_MODAL_DATA (name/email, missing-field fallback), getValues() trimming and null/undefined coercion, and the modalTitle TemplateRef capture.

What changes were proposed in this PR?

Adds a behavior-focused unit test spec for RegistrationRequestModalComponent. Tests cover:

  • Constructor hydration from NZ_MODAL_DATA (name, email, missing-field fallback)
  • getValues() trimming and null/undefined coercion
  • modalTitle TemplateRef capture

Any related issues, documentation, discussions?

Related to #5601

How was this PR tested?

Spec verified with npx ng test --watch=false --include='**/registration-request-modal.component.spec.ts'. 7 tests passing.

Was this PR authored or co-authored using generative AI tooling?

Generated-by: Claude Code (Opus4.7 1M context)

Covers constructor hydration from NZ_MODAL_DATA (name/email, missing-field fallback),
getValues() trimming and null/undefined coercion, and the modalTitle TemplateRef
capture.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@github-actions github-actions Bot added the frontend Changes related to the frontend GUI label Jun 9, 2026

@xuang7 xuang7 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Thanks for the PR. Overall, it looks good to me. I'm not fully sure why this PR is linked to #5167, since I don't see related context there. Could you please open a separate issue for this PR?

@codecov-commenter

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 52.25%. Comparing base (564ccdb) to head (79c4882).
⚠️ Report is 8 commits behind head on main.

Additional details and impacted files
@@             Coverage Diff              @@
##               main    #5583      +/-   ##
============================================
+ Coverage     52.17%   52.25%   +0.07%     
  Complexity     2482     2482              
============================================
  Files          1068     1068              
  Lines         41311    41311              
  Branches       4439     4439              
============================================
+ Hits          21556    21585      +29     
+ Misses        18490    18459      -31     
- Partials       1265     1267       +2     
Flag Coverage Δ *Carryforward flag
access-control-service 64.61% <ø> (ø) Carriedforward from 564ccdb
agent-service 33.76% <ø> (ø) Carriedforward from 564ccdb
amber 53.28% <ø> (ø) Carriedforward from 564ccdb
computing-unit-managing-service 1.65% <ø> (ø) Carriedforward from 564ccdb
config-service 56.06% <ø> (ø) Carriedforward from 564ccdb
file-service 38.32% <ø> (ø) Carriedforward from 564ccdb
frontend 46.59% <ø> (+0.17%) ⬆️
pyamber 90.72% <ø> (ø) Carriedforward from 564ccdb
python 90.75% <ø> (ø) Carriedforward from 564ccdb
workflow-compiling-service 58.69% <ø> (ø) Carriedforward from 564ccdb

*This pull request uses carry forward flags. Click here to find out more.

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

🚀 New features to boost your workflow:
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

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

Labels

frontend Changes related to the frontend GUI

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants