Skip to content

Conversation

@yongdiw
Copy link
Contributor

@yongdiw yongdiw commented Dec 10, 2025

This pull request introduces new infrastructure and utilities to support end-to-end (E2E) testing for the NativeAuthSample in the MSAL browser samples. The most significant changes include the addition of configuration files and utility modules for handling test configuration, email-based OTP flows, and proxy management. It also updates the pipeline configuration to include the new sample and fixes a path in the Jest configuration.

@yongdiw yongdiw requested a review from shenj as a code owner December 10, 2025 13:21
Copilot AI review requested due to automatic review settings December 10, 2025 13:21
Copy link
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 introduces comprehensive end-to-end testing infrastructure for the NativeAuthSample, enabling automated testing of native authentication flows including sign-up, sign-in, sign-out, and password reset scenarios. The implementation adds test utilities for email-based OTP verification, CORS proxy management, and centralized configuration handling.

Key changes:

  • Adds 4 comprehensive test specification files covering positive and negative authentication flows
  • Implements reusable utility modules for email provider integration, proxy management, and configuration parsing
  • Fixes Jest configuration path and adds NativeAuthSample to the 3p-e2e pipeline

Reviewed changes

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

Show a summary per file
File Description
samples/msal-browser-samples/NativeAuthSample/test/signup.spec.ts Comprehensive sign-up flow tests with email+password and email+OTP scenarios including positive and negative test cases
samples/msal-browser-samples/NativeAuthSample/test/signin.spec.ts Sign-in flow tests covering email+password and email+OTP authentication methods with error handling scenarios
samples/msal-browser-samples/NativeAuthSample/test/signout.spec.ts Sign-out flow test validating session termination after successful authentication
samples/msal-browser-samples/NativeAuthSample/test/resetpassword.spec.ts Password reset flow tests with positive and negative scenarios including OTP verification
samples/msal-browser-samples/NativeAuthSample/test/configUtils.ts Centralized configuration management utility for test data, tenant info, and native auth settings
samples/msal-browser-samples/NativeAuthSample/test/emailProviderUtils.ts Mail.tm API integration for automated email inbox creation and OTP code extraction
samples/msal-browser-samples/NativeAuthSample/test/proxyUtils.ts CORS proxy server management utilities for test environment setup
samples/msal-browser-samples/NativeAuthSample/nativeAuthConfig.json Native authentication configuration including client IDs, tenant details, and test credentials
samples/msal-browser-samples/NativeAuthSample/jest.config.cjs Fixed Jest preset path from incorrect deep nesting to correct relative path
.pipelines/3p-e2e.yml Added NativeAuthSample to the list of samples to test in the 3p-e2e pipeline

tnorling
tnorling previously approved these changes Dec 16, 2025
hectormmg
hectormmg previously approved these changes Dec 18, 2025
@yongdiw yongdiw dismissed stale reviews from hectormmg and tnorling via c7122b1 December 19, 2025 11:12
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.

4 participants