Implement config validation tests with comprehensive flag combination checks - #7
Draft
thesprockee with Copilot wants to merge 38 commits into
Draft
Implement config validation tests with comprehensive flag combination checks#7thesprockee with Copilot wants to merge 38 commits into
thesprockee with Copilot wants to merge 38 commits into
Conversation
* Update deps * Add build tools and instructions * Add script used to supervise EchoVRCE competitive servers * Update Go version to 1.25 in workflows for benchmarks, release, and build binaries * Update .github/workflows/benchmarks.yml Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * Update .github/workflows/build-release-binaries.yml Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> --------- Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
…tectures and improve version handling
…JWT auth (#5) Features: - Unified CLI using Cobra/Viper replacing individual command binaries - GraphQL API for session events with pagination - Real-time WebSocket streaming for match frames - Prometheus metrics endpoint for monitoring - Player lookup service with caching and rate limiting - StorageManager for nevrcap files with retention policies - AMQP publishing support for event distribution Infrastructure: - Docker Compose setup with MongoDB integration - GitHub Actions workflow for release binaries - GitHub Container Registry (ghcr.io) publishing Security: - JWT middleware for API authentication - Fixed SQL injection vulnerability (code scanning alert #6) Dependencies: - Updated to nevr-capture v3.2.0
- Removed viper dependency and replaced it with direct flag variable assignments for better clarity and control. - Updated the agent, API server, converter, replayer, and send events commands to use local variables for flags instead of viper. - Enhanced configuration loading to prioritize command-line flags over config files and environment variables. - Improved JWT token handling in the agent command, ensuring CLI flags take precedence. - Added detailed logging for JWT token status in the agent command. - Updated the configuration struct to remove unnecessary mapstructure tags and ensure YAML compatibility. - Implemented environment variable overrides for configuration settings, supporting both NEVR_ and EVR_ prefixes for backward compatibility. - Cleaned up the go.mod file by removing unused dependencies related to viper.
- Removed Events field from StreamConfig and related flags in agent command. - Updated event streaming URL to use WebSocket protocol. - Deleted the send events command and associated logic. - Simplified event handling in the agent by removing EventsAPIWriter. - Adjusted API server routes to focus on WebSocket streaming. - Updated documentation to reflect changes in event handling and API usage. - Cleaned up unused code and configurations related to events API.
…rcap file writing
…related documentation
…during disconnections
- Introduce new API endpoints for listing matches and retrieving match details. - Update capture size and retention configuration to accept human-readable formats. - Implement storage manager for handling match data with active and completed states. - Add tests for parsing and formatting byte sizes.
- Add --recursive flag to recursively search directories - Add --glob flag for pattern matching (e.g., '*.echoreplay') - Add --validate flag for round-trip data integrity validation - Validation uses raw JSON comparison to ensure ALL fields preserved - Fix import paths for apigame/v1 migration in replayer and validator - Prevent --output with --recursive/--glob (auto-generated outputs) - Prevent --validate with --exclude-bones (validation would fail)
* fix/optimize-streams: feat(converter): add recursive/glob search and round-trip validation Add node ID configuration for agent instances Enhance match retrieval and storage management Add StreamHub integration and endpoint for listing active streams Add .gitignore and project configuration file for language server setup Skip storing session frames without events in StoreSessionFrame function Implement disk buffering for WebSocketWriter to handle frame storage during disconnections Update sessionEventDatabaseName to use 'nevr_telemetry' in resolvers and types Implement automatic reconnection for WebSocketWriter with exponential backoff Add frame counting and logging for WebSocket message processing Make the JWT secret optional, update WebSocket endpoint, and improve related documentation Update output format to 'nevrcap' and improve logging message for nevrcap file writing Fix event processor Refactor agent to remove events API and streamline event streaming Add 'bin/' to .gitignore to exclude binary output from version control Refactor configuration files and Docker setup for improved clarity and functionality Refactor command-line flag handling and configuration loading
- Add tier 1 (critical) test prompt: 285 test cases for core converter functions - Add tier 2 (high) test prompt: 160 test cases for JSON comparison and path handling - Add tier 3 (medium) test prompt: 72 test cases for utility functions - Add config validation test prompt: 150 test cases with refactoring guidance - Total 667 planned test cases targeting 80%+ coverage - Includes test fixtures, helper functions, and acceptance criteria - Ready for implementation by test agents
- Expanded ValidateConverterConfig() with 5 validation categories - Moved validation logic from converter.go to config layer - Added converter env var support to applyEnvOverrides() - Created 52 comprehensive test cases in converter_validation_test.go - All tests passing Co-authored-by: thesprockee <962164+thesprockee@users.noreply.github.com>
- Created converter_test.go with 45+ test cases for utility functions - Tests cover: command structure, format detection, path logic, file discovery - Note: cmd/agent tests blocked by pre-existing build issues in replayer.go - All config validation tests passing with 100% coverage on critical functions Co-authored-by: thesprockee <962164+thesprockee@users.noreply.github.com>
- Documented Phase 1 completion with 52 tests and excellent coverage - Explained build issues blocking Phases 2-4 implementation - Provided examples of validation improvements and benefits - Added instructions for running tests and next steps Co-authored-by: thesprockee <962164+thesprockee@users.noreply.github.com>
- Fixed line count in TEST_IMPLEMENTATION_SUMMARY.md (889 vs 1,142) - Added clarifying comment about env var prefix handling (getEnv checks both NEVR_ and EVR_ prefixes) - No functional changes needed Co-authored-by: thesprockee <962164+thesprockee@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Implement test for configuration validation and converters
Implement config validation tests with comprehensive flag combination checks
Feb 10, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Implements test coverage specified in
.prompts/test-config-validation.md. Refactors validation logic from command execution to config layer and adds 52 test cases achieving 100% coverage on critical validation functions.Changes
Validation Refactoring
converter.gotoValidateConverterConfig()--validate+--recursive,--recursivewithout--output-dirEnvironment Variables
EVR_CONVERTER_*,NEVR_CONVERTER_*)parseBool()helper accepting "true/1/yes/on"Test Coverage
internal/config/converter_validation_test.gowith 52 testsValidateConverterConfig100%,validateRequiredFields100%,validateFormat100%,validateFlagCombinations86.7%,validateFileSystem79.2%cmd/agent/converter_test.go(blocked by pre-existing build issues)Example
Before:
After:
Notes
Pre-existing build failures prevent testing
cmd/agentfunctions (missingnevr-common/v4/gen/go/apigame/v1, undefinedevents.NewWithDefaultSensors). Config tests verified working.Original prompt
💡 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.