Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release v1.2.0 - Refactoring and Improvements #12

Merged
merged 2 commits into from
Dec 5, 2024
Merged

Conversation

shiningflash
Copy link
Owner

Release Overview

This release introduces version v1.1.0 of the project, focusing exclusively on code refactoring, test reorganization, and improvements to the project structure. This is a non-breaking release aimed at improving maintainability and scalability for future development.


Key Updates

  1. Refactoring to common Module:

    • Migrated utility files (logger.py, validators.py, exceptions.py, retry.py, requests.py) from src/sdk/utils/ to src/common/.
    • Centralized shared functionality in the common module for improved modularity.
  2. Test Structure Reorganization:

    • Reorganized the tests/ directory into three categories:
      • unit/: For testing individual components of the SDK and server.
      • integration/: For testing interactions between SDK/server components.
      • e2e/: For end-to-end workflows.
    • Introduced test_sdk/ and test_server/ subdirectories within unit and integration for clearer test categorization.
  3. General Improvements:

    • Updated all imports to align with the new file structure.
    • Removed redundant __init__.py files where not needed.

Benefits

  • Improved project modularity through centralized utilities (common module).
  • Enhanced test organization for targeted and efficient testing.
  • Prepared the codebase for future scalability and feature additions.

Validation

  • All tests, including unit, integration, and e2e, have been successfully executed.
  • CI/CD pipelines have been verified for the updated project structure.

Notes

  • This release does not include new features or functionality updates.
  • Backward compatibility remains unaffected as these changes are structural.

- Grouped tests by type (unit, integration, e2e) and module (sdk, server).
- Renamed directories for better readability and alignment with best practices.
- Removed unnecessary __init__.py files from test directories.
- Centralized shared test configurations in conftest.py for reusability.
- Improved flexibility for running module-specific and type-specific tests.

This refactor enhances maintainability, simplifies navigation, and prepares the test suite for future expansion.
Refactor: migrate utils to common module and reorganize test structure
Copy link

github-actions bot commented Dec 5, 2024

Coverage

Coverage Report
FileStmtsMissCoverMissing
src/common
   __init__.py00100% 
   exceptions.py5299 83%
   logger.py220100% 
   requests.py1544 73%
   retry.py2111 95%
   validators.py6222 97%
src/sdk
   __init__.py00100% 
   client.py390100% 
src/sdk/features
   __init__.py00100% 
   contacts.py380100% 
   messages.py3022 93%
src/sdk/schemas
   __init__.py00100% 
   contacts.py2633 88%
   messages.py2722 93%
src/server
   __init__.py00100% 
   app.py2533 88%
   schemas.py80100% 
TOTAL3652693% 

Tests Skipped Failures Errors Time
56 0 💤 0 ❌ 0 🔥 6.879s ⏱️

@shiningflash shiningflash self-assigned this Dec 5, 2024
@shiningflash shiningflash merged commit d45ecfc into main Dec 5, 2024
1 check passed
@shiningflash shiningflash changed the title Release v1.1.0 - Refactoring and Improvements Release v1.2.0 - Refactoring and Improvements Dec 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant