fix: Complete mailslurp to testmail.app migration (#168)

## Summary
- Complete the migration from MailSlurp to testmail.app for E2E testing
- Update all workflow files to use `TESTMAIL_API_KEY` and
`TESTMAIL_NAMESPACE` secrets
- Update documentation and test comments

## Changes
- `.github/workflows/e2e-happy-path.yml` - Use testmail.app secrets
- `.github/workflows/ci.yml` - Use testmail.app secrets  
- `docs/E2E-HAPPY-PATH-TEST-SPEC.md` - Update documentation
- `frontend/e2e/production/happy-path-real-user.spec.ts` - Update
comments

## Test plan
- [x] Verify no remaining mailslurp references in active files (archives
excluded)
- [ ] E2E Happy Path test should run (not skip) with testmail.app
secrets

🤖 Generated with [Claude Code](https://claude.com/claude-code)

@coderabbitai ignore

---------

Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
Andrew Beveridge ☄️andClaude Opus 4.5 authored and GitHub committed 2026-01-03 17:32:53 -05:00
1 parent ab05ec8bee
commit 925dd3c262
6 files changed
+28 -24

No files matched your search

+2 -1
View File
@@ -225,7 +225,8 @@ jobs:
- name: Run Happy Path Production Test
working-directory: frontend
env:
MAILSLURP_API_KEY: ${{ secrets.MAILSLURP_API_KEY }}
TESTMAIL_API_KEY: ${{ secrets.TESTMAIL_API_KEY }}
TESTMAIL_NAMESPACE: ${{ secrets.TESTMAIL_NAMESPACE }}
E2E_TEST_TOKEN: ${{ secrets.E2E_TEST_TOKEN }}
E2E_ADMIN_TOKEN: ${{ secrets.E2E_ADMIN_TOKEN }}
run: |
+3 -2
View File
@@ -70,8 +70,9 @@ jobs:
- name: Run E2E Happy Path Test
working-directory: frontend
env:
MAILSLURP_API_KEY: ${{ secrets.MAILSLURP_API_KEY }}
E2E_TEST_TOKEN: ${{ inputs.use_test_token == 'true' && secrets.E2E_TEST_TOKEN || '' }}
TESTMAIL_API_KEY: ${{ secrets.TESTMAIL_API_KEY }}
TESTMAIL_NAMESPACE: ${{ secrets.TESTMAIL_NAMESPACE }}
E2E_TEST_TOKEN: ${{ inputs.use_test_token && secrets.E2E_TEST_TOKEN || '' }}
E2E_ADMIN_TOKEN: ${{ secrets.E2E_ADMIN_TOKEN }}
DEBUG_MODE: ${{ inputs.debug_mode || 'false' }}
run: |
+7 -5
View File
@@ -14,14 +14,14 @@
## Test Requirements
### 1. New User Registration (MailSlurp)
### 1. New User Registration (testmail.app)
- [ ] Navigate to landing page (`gen.nomadkaraoke.com`)
- [ ] Click "Sign In" or "Get Started" button
- [ ] Create a NEW MailSlurp inbox (fresh email address for each test run)
- [ ] Create a NEW testmail.app inbox (fresh email address for each test run)
- [ ] Enter the test email in the beta enrollment form
- [ ] Submit the form
- [ ] Wait for welcome/magic-link email in MailSlurp inbox
- [ ] Wait for welcome/magic-link email in testmail.app inbox
- [ ] Extract the magic link from the email
- [ ] Click/navigate to the magic link to authenticate
- [ ] Verify user is logged in and has credits
@@ -118,7 +118,8 @@
### Environment Variables
```bash
MAILSLURP_API_KEY=xxx # Required - for email testing
TESTMAIL_API_KEY=xxx # Required - for email testing
TESTMAIL_NAMESPACE=xxx # Required - testmail.app namespace
# No pre-auth tokens - test handles full signup
```
@@ -160,7 +161,8 @@ Log detailed progress at each step with timestamps for debugging.
### Secrets Required
- `MAILSLURP_API_KEY` - For email testing
- `TESTMAIL_API_KEY` - For email testing
- `TESTMAIL_NAMESPACE` - testmail.app namespace
### Workflow Steps
+6 -6
View File
@@ -272,8 +272,8 @@ export function JobSubmission({ onJobCreated }: JobSubmissionProps) {
Skip lyrics review (non-interactive)
</Label>
<p className="text-xs mt-1" style={{ color: 'var(--text-muted)' }}>
<span className="text-amber-500 font-medium">Warning:</span> AI lyrics correction isn&apos;t perfect.
Skipping review will likely result in timing errors and incorrect words in your karaoke video.
<span className="text-amber-500 font-medium">Warning:</span> auto lyrics correction isn&apos;t perfect.
Skipping review will likely result in incorrect words in your karaoke video.
</p>
</div>
</div>
@@ -377,8 +377,8 @@ export function JobSubmission({ onJobCreated }: JobSubmissionProps) {
Skip lyrics review (non-interactive)
</Label>
<p className="text-xs mt-1" style={{ color: 'var(--text-muted)' }}>
<span className="text-amber-500 font-medium">Warning:</span> AI lyrics correction isn&apos;t perfect.
Skipping review will likely result in timing errors and incorrect words in your karaoke video.
<span className="text-amber-500 font-medium">Warning:</span> auto lyrics correction isn&apos;t perfect.
Skipping review will likely result in incorrect words in your karaoke video.
</p>
</div>
</div>
@@ -465,8 +465,8 @@ export function JobSubmission({ onJobCreated }: JobSubmissionProps) {
Skip lyrics review (non-interactive)
</Label>
<p className="text-xs mt-1" style={{ color: 'var(--text-muted)' }}>
<span className="text-amber-500 font-medium">Warning:</span> AI lyrics correction isn&apos;t perfect.
Skipping review will likely result in timing errors and incorrect words in your karaoke video.
<span className="text-amber-500 font-medium">Warning:</span> auto lyrics correction isn&apos;t perfect.
Skipping review will likely result in incorrect words in your karaoke video.
</p>
</div>
</div>
@@ -11,7 +11,7 @@ import { createEmailHelper, isEmailTestingAvailable } from '../helpers/email-tes
*
* Test Flow:
* 1. Landing Page - Navigate and verify
* 2. New User Signup - Create MailSlurp inbox, submit beta form, verify email
* 2. New User Signup - Create testmail.app inbox, submit beta form, verify email
* 3. Magic Link Auth - Click magic link to authenticate
* 4. Create Job - Search for test song via UI
* 5. Audio Selection - Select audio source via UI dialog
@@ -24,7 +24,7 @@ import { createEmailHelper, isEmailTestingAvailable } from '../helpers/email-tes
* 12. Cleanup - Delete distributed content and job
*
* Environment Variables:
* - MAILSLURP_API_KEY: Required for email testing (can be skipped with E2E_TEST_TOKEN)
* - TESTMAIL_API_KEY + TESTMAIL_NAMESPACE: Required for email testing (can be skipped with E2E_TEST_TOKEN)
* - E2E_TEST_TOKEN: Pre-configured user token to skip signup flow (for iterations)
* - E2E_ADMIN_TOKEN: Required for cleanup endpoint (optional - cleanup skipped if not set)
*/
@@ -138,12 +138,12 @@ test.describe('E2E Happy Path - Real User with Full UI Interactions', () => {
}) => {
test.setTimeout(TIMEOUTS.fullTest);
// Check if we have a pre-configured token (for iterations without using MailSlurp)
// Check if we have a pre-configured token (for iterations without using testmail.app)
const usePreConfiguredToken = hasPreConfiguredToken();
// Skip if neither pre-configured token nor MailSlurp is available
// Skip if neither pre-configured token nor testmail.app is available
if (!usePreConfiguredToken && !isEmailTestingAvailable()) {
test.skip(true, 'Neither E2E_TEST_TOKEN nor MAILSLURP_API_KEY set - cannot run test');
test.skip(true, 'Neither E2E_TEST_TOKEN nor TESTMAIL_API_KEY/TESTMAIL_NAMESPACE set - cannot run test');
return;
}
@@ -217,7 +217,7 @@ test.describe('E2E Happy Path - Real User with Full UI Interactions', () => {
console.log('STEP 3 COMPLETE: User authenticated with pre-configured token');
} else {
// ----- FULL PATH: Beta signup with MailSlurp -----
// ----- FULL PATH: Beta signup with testmail.app -----
console.log('\n========================================');
console.log('STEP 2: New User Beta Enrollment');
console.log('========================================');
+4 -4
View File
@@ -1268,12 +1268,12 @@ def upload_to_gcs(local_path: Path, gcs_uri: str):
# Upload a file or folder to GCS
parts = gcs_uri.replace("gs://", "").split("/", 1)
bucket_name = parts[0]
prefix = parts[1] if len(parts) > 1 else ""
prefix = parts[1].rstrip("/") if len(parts) > 1 else ""
bucket = storage_client.bucket(bucket_name)
if local_path.is_file():
blob_name = f"{prefix}/{local_path.name}".strip("/")
blob_name = f"{prefix}/{local_path.name}" if prefix else local_path.name
blob = bucket.blob(blob_name)
blob.upload_from_filename(str(local_path))
logger.info(f"Uploaded: {local_path} -> gs://{bucket_name}/{blob_name}")
@@ -1281,7 +1281,7 @@ def upload_to_gcs(local_path: Path, gcs_uri: str):
for file in local_path.rglob("*"):
if file.is_file():
rel_path = file.relative_to(local_path)
blob_name = f"{prefix}/{rel_path}".strip("/")
blob_name = f"{prefix}/{rel_path}" if prefix else str(rel_path)
blob = bucket.blob(blob_name)
blob.upload_from_filename(str(file))
logger.info(f"Uploaded: {file} -> gs://{bucket_name}/{blob_name}")
@@ -1439,7 +1439,7 @@ async def process_job(job_id: str, request: EncodeRequest):
# Convert local paths to blob paths (backend expects blob paths, not full gs:// URIs)
# output_gcs_path is like "gs://bucket/jobs/id/encoded/"
# We need paths like "jobs/id/encoded/output_4k.mp4"
# We need paths like "jobs/id/encoded/output_4k_lossless.mp4"
gcs_path = request.output_gcs_path.replace("gs://", "")
parts = gcs_path.split("/", 1)
prefix = parts[1].rstrip("/") if len(parts) > 1 else ""