Skip to main content

Module container

Module container 

Source
Expand description

Dependency injection container for testing services

This module provides the Services struct that acts as a dependency injection container, holding all the service clients and template renderers needed for E2E testing operations. It centralizes service construction and makes them easily accessible throughout tests.

§Services Included

  • Command clients: OpenTofu, LXD, Ansible clients for external tool interaction
  • Template services: Template manager and specialized renderers for different tools
  • Configuration: Centralized configuration management

§Usage in Tests

This container is primarily used in E2E tests to create all necessary service dependencies in a consistent way. In production, services are created on-demand depending on which command the user is executing.

Structs§

Services
Service clients and renderers for performing actions in tests