Fix migration docs, test expectations, and import paths#75
Conversation
|
@copilot can you also include this? |
- Updated Railway section in migration.md to include both PLATFORM_REDIS_URL and WEBHOOK_REDIS_URL - Fixed button text in BaseCommand.ts from 'Start Activation' to 'Activate Admin Access' - Updated test expectation in adminCommands.test.ts to match production button text - Fixed import path in baseCommand.test.ts (from ../../types to ../types) - Reordered imports in validationService.test.ts to satisfy sort-imports lint rule Co-authored-by: warengonzaga <15052701+warengonzaga@users.noreply.github.com>
I see you're referring to PR #72 discussion r2422510569. However, the current PR (copilot/update-env-vars-and-tests) is focused on the specific issues mentioned in the problem statement:
Could you clarify which specific changes from PR #72 discussion you'd like me to include in this PR? The discussion link references a different PR with many test file changes. Should I:
Warning Firewall rules blocked me from connecting to one or more addresses (expand for details)I tried to connect to the following addresses, but was blocked by firewall rules:
If you need me to access, download, or install something from one of these locations, you can either:
|
Include that review from #72 to this PR along with 4 issues or issues we fixed in this PR. |
- Sorted vitest imports alphabetically in all test files (afterEach, beforeEach, describe, expect, it, vi) - Fixed import sorting violations across 16 test files - All 737 tests still pass - All sort-imports lint errors in test files resolved Co-authored-by: warengonzaga <15052701+warengonzaga@users.noreply.github.com>
... Applied all import sorting fixes from PR #72 review to this PR. Fixed vitest import sorting in 16 test files to alphabetical order (afterEach, beforeEach, describe, expect, it, vi). All changes committed in 35962da and the new commit. All 737 tests pass and all sort-imports lint errors in test files are resolved. Warning Firewall rules blocked me from connecting to one or more addresses (expand for details)I tried to connect to the following addresses, but was blocked by firewall rules:
If you need me to access, download, or install something from one of these locations, you can either:
|
|
@copilot how compatible is this with |
There was a problem hiding this comment.
Pull Request Overview
This PR addresses documentation gaps, test inconsistencies, and code quality issues to ensure alignment between tests, documentation, and production code. The changes improve Railway deployment documentation accuracy and resolve ESLint violations across the test suite.
- Fixed Railway environment variables documentation to include both required Redis URLs
- Corrected admin activation button text consistency between tests and production code
- Fixed incorrect import path that was escaping the src directory
- Resolved alphabetical import ordering violations across 16 test files
Reviewed Changes
Copilot reviewed 20 out of 20 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| docs/migration.md | Added missing PLATFORM_REDIS_URL environment variable for Railway deployments |
| src/commands/base/BaseCommand.ts | Updated admin activation button text to match test expectations |
| src/tests/adminCommands.test.ts | Fixed test expectation for admin activation button text |
| src/tests/baseCommand.test.ts | Corrected BotContext import path to stay within src directory |
| src/tests/validationService.test.ts | Reordered imports alphabetically to fix ESLint violation |
| src/tests/*.test.ts (15 files) | Fixed vitest import ordering to satisfy sort-imports ESLint rule |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
This PR is fully compatible with the Compatibility Details:
Changed Files:
The PR can be merged into |
Overview
This PR addresses several documentation and test issues to ensure consistency between tests, documentation, and production code.
Changes
1. Railway Environment Variables Documentation (
docs/migration.md)The Railway deployment section was missing the
PLATFORM_REDIS_URLenvironment variable, which is required for the BotsStore to connect to its Redis instance. Updated the Railway environment variables snippet to include both Redis URLs:This ensures Railway users configure both Redis instances correctly, matching the Docker deployment documentation.
2. Admin Activation Button Text Consistency
The test in
src/__tests__/adminCommands.test.tswas expecting the outdated button text'🚀 Start Activation', while the production code should use'🚀 Activate Admin Access'for consistency with the dedicated activation handler.Fixed both:
src/commands/base/BaseCommand.tsto use the correct button text3. Import Path Correction (
src/__tests__/baseCommand.test.ts)Fixed an incorrect import path that was escaping the src directory:
4. Import Ordering (
src/__tests__/validationService.test.ts)Reordered imports alphabetically to satisfy the
sort-importsESLint rule:5. Test Files Import Sorting (Per PR #72 Review)
Fixed
sort-importsESLint violations across 15 additional test files by reordering vitest imports alphabetically:Files updated:
Testing
sort-importsviolations in test files resolvedImpact
These are minimal, surgical changes that:
Created from VS Code via the GitHub Pull Request extension.
Original prompt
Created from VS Code via the GitHub Pull Request extension.
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.