Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: refactor unified_test to split out scenario execution #1737

Conversation

justinsb
Copy link
Collaborator

@justinsb justinsb commented May 8, 2024

Working towards being able to run samples & fixtures the same way.

Working towards being able to run samples & fixtures the same way.
@justinsb justinsb force-pushed the harmonize_samples_and_fixtures_step2 branch from e231329 to ce485f6 Compare May 8, 2024 15:08
Copy link
Collaborator

@acpana acpana left a comment

Choose a reason for hiding this comment

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

/hold question about that extra indent

I think I can see how we are going to reuse runScenario for the fixtures too.

/lgtm
/approve

}

func runScenario(ctx context.Context, t *testing.T, testPause bool, fixture resourcefixture.ResourceFixture, loadFixture func(project testgcp.GCPProject, uniqueID string) (*unstructured.Unstructured, create.CreateDeleteTestOptions)) {
// Extra indentation to avoid merge conflicts
Copy link
Collaborator

Choose a reason for hiding this comment

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

to avoid merge conflicts in this PR 😛 ? or in the future, in which case I'd be curious how this works to fool git diff hehe ? 👀

Copy link
Collaborator

Choose a reason for hiding this comment

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

Just learnt this trick today 😆

cancel()
}

func runScenario(ctx context.Context, t *testing.T, testPause bool, fixture resourcefixture.ResourceFixture, loadFixture func(project testgcp.GCPProject, uniqueID string) (*unstructured.Unstructured, create.CreateDeleteTestOptions)) {
Copy link
Collaborator

Choose a reason for hiding this comment

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

But also could we rename this to runTest? Scenario makes me think of the step/ scenario based testing but if that's on purpose then never mind 😛

Copy link
Collaborator

Choose a reason for hiding this comment

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

Let's have this PR goes in and then we can discuss/improve in follow up changes. 🥂

@yuwenma
Copy link
Collaborator

yuwenma commented May 22, 2024

/lgtm
/approve

Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: acpana, yuwenma

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@yuwenma
Copy link
Collaborator

yuwenma commented May 24, 2024

/hold cancel

@google-oss-prow google-oss-prow bot merged commit 4cfd5b6 into GoogleCloudPlatform:master May 24, 2024
10 of 11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants