Skip to content

feat: integration tests for react generator #118

@kriscoleman

Description

@kriscoleman

feat: integration tests for react generator

Description

The CLI supports an integration testing framework designed to validate that generated feature flag clients are usable and functional within their target environments. Currently, the React generator lacks integration test coverage.

We should create an integration test for the React generator following the structure outlined in the testing documentation.

📄 Relevant Documentation:
Integration Testing Pattern


Tasks

  • Scaffold a minimal React test app (e.g., using create-react-app or Vite)
  • Generate a feature flag client using the React generator
  • Validate that the generated client compiles and integrates with a simple component
  • Write a basic test to verify flag evaluation in the React environment
  • Add the test to the integration test suite and CI
  • Update documentation if needed for React-specific setup

Acceptance Criteria

  • ✅ React generator has at least one integration test
  • ✅ Generated React code integrates into a functional React component
  • ✅ Integration test runs successfully in the CI pipeline
  • ✅ The test adheres to the CLI's integration test pattern

Additional Notes

This test ensures that the React generator produces code that works correctly in a modern front-end stack and helps prevent regressions related to JSX integration or runtime behavior.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions