Skip to content

Add regression coverage for PowerShell scalar and array cardinality #55

Description

@iotaverbum-core

Problem

R1 publication verification exposed a PowerShell strict-mode failure when a filtered pipeline returned one object rather than an array. Accessing .Count on that scalar failed after the release and asset had already been created.

Required change

PowerShell operator scripts must normalize any zero-, one-, or many-result pipeline before performing cardinality checks.

Acceptance criteria

  • Filtered results used for cardinality checks are always wrapped with @(...) around the entire pipeline.
  • Regression tests cover zero, one, and multiple matching records or assets.
  • Strict mode remains enabled in tested scripts.
  • A single matching asset verifies successfully.
  • Zero or duplicate matching assets fail closed with precise messages.
  • No test makes a provider request or mutates campaign evidence.

Scope

Audit all PowerShell scripts used for campaign closure, publication preparation, release creation, asset upload, and verification for the same scalar-versus-array assumption.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions