Skip to content

Address feedback on flaky test fix for OpenAI health check tests#14929

Draft
Copilot wants to merge 2 commits intofix-openai-flakyfrom
copilot/sub-pr-14928
Draft

Address feedback on flaky test fix for OpenAI health check tests#14929
Copilot wants to merge 2 commits intofix-openai-flakyfrom
copilot/sub-pr-14928

Conversation

Copy link
Contributor

Copilot AI commented Mar 4, 2026

Description

Addresses review feedback on #14928. Both OpenAI functional tests were removing the resource_check health check annotation by its specific internal name. The updated approach removes all HealthCheckAnnotations except blocking_check, which is the only health check each test actually exercises.

Changes:

  • DependentResourceWaitsForOpenAIModelResourceWithHealthCheckToBeHealthy: replace targeted resource_check removal with a loop that strips all health checks except blocking_check from the parent OpenAI resource
  • DependentResourceWaitsForOpenAIResourceWithHealthCheckToBeHealthy: same pattern; also removes the Assert.Single that asserted on the internal resource_check name
// Before: coupled to internal annotation name
var statusPageHealthCheck = Enumerable.Single(openai.Resource.Annotations,
    x => x is HealthCheckAnnotation hca && hca.Key == "resource_check");
openai.Resource.Annotations.Remove(statusPageHealthCheck);

// After: removes anything the test doesn't care about
foreach (var annotation in openai.Resource.Annotations
    .OfType<HealthCheckAnnotation>()
    .Where(hca => hca.Key != "blocking_check")
    .ToList())
{
    openai.Resource.Annotations.Remove(annotation);
}

Checklist

  • Is this feature complete?
    • Yes. Ready to ship.
    • No. Follow-up changes expected.
  • Are you including unit tests for the changes and scenario tests if relevant?
    • Yes
    • No
  • Did you add public API?
    • Yes
      • If yes, did you have an API Review for it?
        • Yes
        • No
      • Did you add <remarks /> and <code /> elements on your triple slash comments?
        • Yes
        • No
    • No
  • Does the change make any security assumptions or guarantees?
    • Yes
      • If yes, have you done a threat model and had a security review?
        • Yes
        • No
    • No
  • Does the change require an update in our Aspire docs?

🔒 GitHub Advanced Security automatically protects Copilot coding agent pull requests. You can protect all pull requests by enabling Advanced Security for your repositories. Learn more about Advanced Security.

…penAI tests

Co-authored-by: radical <1472+radical@users.noreply.github.com>
Copilot AI changed the title [WIP] Address feedback on flaky test fix for health checks Address feedback on flaky test fix for OpenAI health check tests Mar 4, 2026
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