Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Jan 8, 2026

Test Directory Organization - COMPLETE ✅

Problem Statement (Chinese)

test目录下面,test-cpu和test-cuda有很多文件,但是文件没有层次和分类,请帮忙整理一个结构,并把分类依据加到test的readme里方便开发者理解和新加ut。

Translation

The test directory contains many files under test-cpu and test-cuda, but the files lack hierarchy and classification. Organize a structure and add classification criteria to the test README to help developers understand and add new unit tests.


✅ All Tasks Completed

  • Create subdirectory structure in test_cpu
  • Move test_cpu files to appropriate subdirectories
  • Create subdirectory structure in test_cuda
  • Move test_cuda files to appropriate subdirectories
  • Update import statements (from ..helpers to ...helpers)
  • Fix symlink for test_llmc_integration.py
  • Update README.md with categorization guide
  • Simplify README and remove STRUCTURE.md
  • Add detailed conftest/helpers/fixtures documentation
  • Verify all files properly organized

📁 New Structure

Reorganized 66 test files into 9 logical categories:

test_cpu/ (33 tests) | test_cuda/ (33 tests)

  • core/ - Core AutoRound API and quantization workflows
  • quantization/ - Quantization techniques (mixed-bit, MXFP, NVFP4)
  • export/ - Model serialization (GGUF, AutoGPTQ, AutoRound format)
  • backends/ - Inference backends (Torch, Marlin, Triton, ExLlamaV2)
  • models/ - Architecture-specific tests (MLLMs, VLMs, MoE, Diffusion)
  • integrations/ - Third-party frameworks (vLLM, SGLang, LLMC)
  • schemes/ - Quantization scheme selection
  • utils/ - Calibration datasets, logging, CLI
  • advanced/ - Multi-GPU, FP8 input

📚 Documentation

README.md - Concise guide with:

  • Directory structure overview
  • Detailed conftest.py, fixtures.py, helpers.py documentation
  • Available fixtures (model paths, dataloaders)
  • Helper functions (model_infer, get_tiny_model, etc.)
  • Code examples for new tests
  • Running tests by category

STRUCTURE.md - Removed per feedback


✨ Benefits

For Developers:

  • Clear, concise documentation
  • Detailed shared utilities documentation (conftest, helpers, fixtures)
  • Easy to find and use existing fixtures
  • Quick onboarding with practical examples

For Contributors:

  • Quick understanding of available test utilities
  • Clear placement guidelines
  • Easy to write new tests using shared fixtures

🔍 Recent Changes

✅ README simplified and made more concise
✅ STRUCTURE.md removed
✅ Added comprehensive conftest/helpers/fixtures documentation
✅ All fixtures and helper functions documented with examples

Original prompt

test目录下面,test-cpu和test-cuda有很多文件,但是文件没有层次和分类,请帮忙整理一个结构,并把分类依据加到test的readme里方便开发者理解和新加ut。


✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

Copilot AI self-assigned this Jan 8, 2026
Copilot AI changed the title [WIP] Organize test directory structure for CPU and CUDA Organize test directory structure with logical categorization Jan 8, 2026
Copilot AI requested a review from xin3he January 8, 2026 06:40
@xin3he
Copy link
Contributor

xin3he commented Jan 8, 2026

@copilot Readme稍微简洁一些,structure.m不需要。另外在README中丰富一下confest, helper, fixture的内容,方便外部开发者快速上手

Copy link
Contributor Author

Copilot AI commented Jan 8, 2026

@copilot Readme稍微简洁一些,structure.m不需要。另外在README中丰富一下confest, helper, fixture的内容,方便外部开发者快速上手

Done! Changes made in commit 674e427:

  1. ✅ README.md simplified and made more concise (reduced from 211 to 127 lines)
  2. ✅ STRUCTURE.md removed
  3. ✅ Added comprehensive documentation for conftest.py, fixtures.py, and helpers.py including:
    • Available fixtures (tiny_opt_model_path, tiny_qwen_model_path, dataloader, etc.)
    • Helper functions (get_model_path, get_tiny_model, model_infer, etc.)
    • Practical code examples showing how to use these utilities

The README now provides clear, concise guidance for external developers to quickly understand and use the shared test utilities.

@xin3he xin3he marked this pull request as ready for review January 8, 2026 06:57
Signed-off-by: He, Xin3 <[email protected]>
Copy link
Contributor

@yiliu30 yiliu30 left a comment

Choose a reason for hiding this comment

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

Cool! LGTM

@xin3he xin3he merged commit 0f6dc76 into main Jan 9, 2026
14 checks passed
@xin3he xin3he deleted the copilot/organize-test-directory-structure branch January 9, 2026 03:19
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