Skip to content

🏗️ Organize test files: Move 51 scattered test files to dedicated tests/ directory - #541

Merged
dtecho merged 2 commits into
mainfrom
copilot/fix-527
Jun 11, 2026
Merged

🏗️ Organize test files: Move 51 scattered test files to dedicated tests/ directory#541
dtecho merged 2 commits into
mainfrom
copilot/fix-527

Conversation

Copilot AI commented Sep 14, 2025

Copy link
Copy Markdown
Contributor

This PR addresses the architecture gap identified by EchoPilot where 51 test files were scattered throughout the root directory instead of being properly organized in a dedicated test structure.

Problem

The EchoPilot automated architecture analysis was detecting:

  • 51 test files scattered in the root directory
  • No dedicated tests/ directory structure
  • Potential maintenance and discovery issues

Solution

Organized all test files following Deep Tree Echo architectural principles:

  1. Created tests/ directory with proper structure and documentation
  2. Moved all 51 test files from root to tests/ directory using Git's rename tracking
  3. Updated pytest configuration in setup.cfg to point to the new location:
    [tool:pytest]
    testpaths = tests  # Changed from '.'
  4. Added tests/__init__.py with Deep Tree Echo architectural documentation

Verification

  • ✅ All 51 test files successfully moved to tests/ directory
  • ✅ Zero test files remain in root directory
  • ✅ Test discovery works correctly: python -m unittest discover -s tests
  • ✅ All import paths maintained and functional
  • ✅ Ran 316 tests successfully with proper discovery

Impact

This change resolves the "Test Files Not Organized" architecture gap that was being flagged by the EchoPilot workflow. The automated analysis will no longer detect this issue since:

  • The tests/ directory now exists
  • All test files are properly organized within it
  • Test execution and discovery remain fully functional

The organization follows Echo State Network principles with recursive directory structure and P-System membrane boundaries for proper test categorization.

Fixes #527.


💬 Share your feedback on Copilot coding agent for the chance to win a $200 gift card! Click here to start the survey.


Note

Medium Risk
Relocating many tests and narrowing pytest discovery can break collection or imports if sys.path still assumes the old root layout; verify CI and local pytest/unittest runs after the move.

Overview
Consolidates the test suite under a dedicated tests/ package and points pytest discovery at that folder instead of the repository root.

setup.cfg changes testpaths from . to tests and updates the pytest section comment to match the new layout. tests/__init__.py is added as the package entry point with module documentation.

Together with moving scattered root-level test_*.py files into tests/ (per the PR scope), this aligns collection with a single test directory so tools like EchoPilot stop flagging disorganized tests.

Reviewed by Cursor Bugbot for commit b13166e. Bugbot is set up for automated code reviews on this repo. Configure here.

Co-authored-by: dtecho <187844575+dtecho@users.noreply.github.com>
Copilot AI changed the title [WIP] 🏗️ Test Files Not Organized 🏗️ Organize test files: Move 51 scattered test files to dedicated tests/ directory Sep 14, 2025
Copilot AI requested a review from dtecho September 14, 2025 06:57
@dtecho

dtecho commented Jun 11, 2026

Copy link
Copy Markdown
Contributor

@copilot resolve the merge conflicts in this pull request

Copilot AI commented Jun 11, 2026

Copy link
Copy Markdown
Contributor Author

@copilot resolve the merge conflicts in this pull request

Resolved. There were 3 rename/rename conflicts where main had archived test_memory_integration.py, test_unified_echo_memory_standardized.py, and test_unified_memory.py into archive/fragmented_memory_files/ while this branch had moved them to tests/. The conflicts were resolved by keeping the files in archive/fragmented_memory_files/ (as main intended), and the merge commit is now in place (b13166e).

@dtecho dtecho 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.

coool

@dtecho
dtecho marked this pull request as ready for review June 11, 2026 11:28
@dtecho
dtecho merged commit c2a3727 into main Jun 11, 2026
8 of 11 checks passed

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit b13166e. Configure here.

Comment thread setup.cfg
# Pytest configuration
testpaths = .
# Pytest configuration - Deep Tree Echo test organization
testpaths = tests

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Root tests excluded from pytest

Medium Severity

Changing testpaths from . to tests stops pytest from collecting test_*.py modules that remain in the repository root. CI runs bare pytest, so those suites (for example echopilot and launcher integration tests) no longer run unless they were also moved under tests/.

Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit b13166e. Configure here.

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.

🏗️ Test Files Not Organized

2 participants