Skip to content

test: add integration test#662

Merged
patrickhoefler merged 7 commits intomainfrom
test/integration
May 11, 2025
Merged

test: add integration test#662
patrickhoefler merged 7 commits intomainfrom
test/integration

Conversation

@patrickhoefler
Copy link
Copy Markdown
Owner

No description provided.

@patrickhoefler patrickhoefler enabled auto-merge (squash) May 10, 2025 19:01
@patrickhoefler patrickhoefler requested a review from Copilot May 10, 2025 19:35
@patrickhoefler patrickhoefler disabled auto-merge May 10, 2025 19:35
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds an integration test to verify that the CLI correctly generates a Dockerfile.dot file, comparing the output against a golden file.

  • Adds a new golden file (Dockerfile.golden.dot) containing the expected Graphviz DOT content.
  • Implements integration tests in integration_test.go that copy an example Dockerfile, run the CLI, and validate the generated DOT file against the golden file.

Reviewed Changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
internal/cmd/testdata/Dockerfile.golden.dot Adds a new golden file with pre-defined DOT content for CLI verification.
internal/cmd/integration_test.go Introduces integration tests for the CLI that generates the DOT file.

@patrickhoefler patrickhoefler requested a review from Copilot May 11, 2025 00:14
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR introduces an integration test to verify that the CLI correctly generates a Dockerfile.dot output by building the project, running a Docker container, and comparing the generated file against a golden file.

  • Adds a new golden DOT file in internal/cmd/testdata/Dockerfile.golden.dot.
  • Implements an integration test in internal/cmd/integration_test.go to build and execute the CLI, then verify its output.

Reviewed Changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
internal/cmd/testdata/Dockerfile.golden.dot Provides the expected DOT graph output for comparison in tests.
internal/cmd/integration_test.go Contains an integration test that builds the project and verifies CLI output against the golden file.

@patrickhoefler patrickhoefler merged commit d7d0929 into main May 11, 2025
8 checks passed
@patrickhoefler patrickhoefler deleted the test/integration branch May 11, 2025 00:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants