Skip to content

Add tests for different parts of the engine #10

@rahulc0dy

Description

@rahulc0dy

This issue aims to introduce automated tests for key components of the Plat-Engine to improve code quality, catch regressions early, and ensure stability as new features are added.

Components to Test

  • Core Initialization and Configuration: Verify that the engine initializes correctly with default and custom settings.
  • Renderer: Test rendering pipeline, draw calls, and scene graph updates.
  • Physics Engine: Validate collision detection, movement integration, and physics responses.
  • Input Handling: Ensure user inputs are correctly captured and processed.
  • Entity System: Test entity creation, component addition/removal, and update loops.
  • Resource Loader: Confirm assets (textures, sounds, levels) load correctly and handle errors gracefully.
  • Level Management: Verify level loading, saving, and transitions.

Goals

  1. Select and configure a testing framework (e.g., Jest, Mocha).
  2. Add unit tests covering public interfaces of each module.
  3. Integrate tests into CI (e.g., GitHub Actions) to run on each PR.
  4. Document testing guidelines and conventions for future contributors.

Acceptance Criteria

  • Tests exist for all listed components.
  • CI pipeline passes all tests on PR and main branch.
  • Documentation added/updated with instructions on how to run tests locally.

Metadata

Metadata

Assignees

No one assigned

    Labels

    invalidThis doesn't seem rightwontfixThis will not be worked on

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions