Skip to content

Consolidate test fixtures into a shared repository for all -PSModule actions #347

@MariusStorhaug

Description

The PSModule organization has four action repositories that each carry their own copy of test
fixture data (source repos, built module outputs). Changes to the fixture structure require
updating multiple repos independently, causing drift and making cross-functional testing
(e.g., build → test → publish pipeline) impossible without manual coordination.

Request

Desired capability

A single shared repository hosts canonical test fixtures that all -PSModule action repos
consume. When a fixture changes, it changes in one place and all consumers pick up the
update. Cross-functional integration tests can run an end-to-end pipeline
(build → test → publish) against the same fixtures without duplicating them.

Current situation

Test fixtures are duplicated across repos:

Repository Local test data
Process-PSModule tests/srcTestRepo/, tests/srcWithManifestTestRepo/
Build-PSModule tests/srcMinimalTestRepo/, tests/srcTestRepo/, tests/srcWithManifestTestRepo/
Test-PSModule tests/outputTestRepo/, tests/srcTestRepo/, tests/srcWithManifestTestRepo/
Publish-PSModule tests/outputs/module/PSModuleTest/

srcTestRepo and srcWithManifestTestRepo are copied across three repos.
outputTestRepo and outputs/module represent the same module at different pipeline stages
but are maintained independently.

User impact

Acceptance criteria

  • A single repository contains all canonical test fixtures (source, built, published forms)
  • Each -PSModule action repo's CI consumes fixtures from the shared repo rather than local copies
  • Local tests/ directories in action repos no longer contain duplicated fixture data
  • A cross-functional integration test can exercise the full pipeline (build → test → publish)
    against shared fixtures
  • Updating a fixture in one place propagates to all consuming repos without manual sync

Technical decisions

Repository location: New repo PSModule/TestData-PSModule (or similar) under the org. Keeps
fixture data versioned and releaseable independently.

Consumption mechanism: GitHub Actions actions/checkout of the fixture repo, or downloading
a tagged release artifact. Avoids git submodules (which add checkout complexity). A lightweight
composite action or reusable step could wrap the checkout for consistency.

Fixture organization: Mirror the pipeline stages:

fixtures/
  source/              # Source repos (srcTestRepo, srcMinimalTestRepo, srcWithManifestTestRepo)
  built/               # Build output (outputTestRepo / outputs/module)
  published/           # (future) Published form for publish-side validation

Versioning: Tagged releases on the fixture repo. Action repos pin to a tag so fixture updates
are explicit and reviewable.

Migration strategy: Incremental — one action repo at a time. Start with Publish-PSModule
(smallest fixture set), validate the pattern, then migrate the others.


Implementation plan

This is a PBI-level issue. Decompose into child tasks:

  • Create the shared fixture repository with initial structure and README
  • Migrate Publish-PSModule test data to shared repo and update its CI
  • Migrate Build-PSModule test data to shared repo and update its CI
  • Migrate Test-PSModule test data to shared repo and update its CI
  • Migrate Process-PSModule test data to shared repo and update its CI
  • Add a cross-functional integration test workflow that exercises build → test → publish
  • Remove local fixture copies from each action repo

Metadata

Metadata

Assignees

No one assigned

    Labels

    No fields configured for Feature.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions