Skip to content

Extract manifest path resolution logic into helper function #59

@coderabbitai

Description

@coderabbitai

Description

The manifest path resolution and creation logic in the run() function within tests/steps/process_steps.rs is verbose and inline, reducing maintainability. This logic should be extracted into a dedicated helper function for better code organisation.

Current Problem

The current implementation contains approximately 23 lines of inline logic for:

  • Resolving absolute vs relative manifest paths
  • Creating temporary manifest files when they don't exist
  • Persisting the manifest files
  • Updating the CLI configuration

Proposed Solution

Extract this logic into a helper function ensure_manifest_exists in the support module that:

  • Takes temporary directory path and CLI file path as parameters
  • Handles absolute/relative path resolution
  • Creates manifest files when missing
  • Returns the resolved manifest path
  • Allows the main run() function to be simplified

References

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions