Skip to content

[Test] Actually invoke the listener on failure case #132229

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

Merged
merged 3 commits into from
Jul 31, 2025

Conversation

ywangd
Copy link
Member

@ywangd ywangd commented Jul 30, 2025

The listener is expected to be called on failure case. This PR does that.

Resolves: #131979

The listener is expected to be called on failure case. This PR does
that.

Resolves: elastic#131979
@ywangd ywangd requested review from tvernum and nielsbauman July 30, 2025 23:16
@ywangd ywangd added >test Issues or PRs that are addressing/adding tests :Core/Infra/Core Core issues without another label auto-backport Automatically create backport pull requests when merged v9.2.0 v9.1.1 labels Jul 30, 2025
@elasticsearchmachine
Copy link
Collaborator

Pinging @elastic/es-core-infra (Team:Core/Infra)

@elasticsearchmachine elasticsearchmachine added the Team:Core/Infra Meta label for core/infra team label Jul 30, 2025
Copy link
Contributor

@nielsbauman nielsbauman left a comment

Choose a reason for hiding this comment

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

LGTM, one optional comment only

Comment on lines 62 to 64
var listener = ActionListener.assertAtLeastOnce(
ActionTestUtils.<AcknowledgedResponse>assertNoSuccessListener(e -> assertTrue(e instanceof IllegalArgumentException))
);
var listener = ActionListener.assertAtLeastOnce(ActionTestUtils.<AcknowledgedResponse>assertNoSuccessListener(e -> {
assertTrue(e instanceof IllegalArgumentException);
}));
Copy link
Contributor

Choose a reason for hiding this comment

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

Nit: I don't think these lines need to be changed - changing the parameter to a lambda block seems redundant.

Copy link
Member Author

Choose a reason for hiding this comment

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

Yeah you are right. It was unintentional. Pushed 2716157

@ywangd ywangd added the auto-merge-without-approval Automatically merge pull request when CI checks pass (NB doesn't wait for reviews!) label Jul 31, 2025
@elasticsearchmachine elasticsearchmachine merged commit bd2cd2c into elastic:main Jul 31, 2025
33 checks passed
@ywangd ywangd deleted the es-131979-fix branch July 31, 2025 08:26
@elasticsearchmachine
Copy link
Collaborator

💚 Backport successful

Status Branch Result
9.1

ywangd added a commit to ywangd/elasticsearch that referenced this pull request Jul 31, 2025
The listener is expected to be called on failure case. This PR does
that.

Resolves: elastic#131979
elasticsearchmachine pushed a commit that referenced this pull request Jul 31, 2025
The listener is expected to be called on failure case. This PR does
that.

Resolves: #131979
smalyshev pushed a commit to smalyshev/elasticsearch that referenced this pull request Jul 31, 2025
The listener is expected to be called on failure case. This PR does
that.

Resolves: elastic#131979
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
auto-backport Automatically create backport pull requests when merged auto-merge-without-approval Automatically merge pull request when CI checks pass (NB doesn't wait for reviews!) :Core/Infra/Core Core issues without another label Team:Core/Infra Meta label for core/infra team >test Issues or PRs that are addressing/adding tests v9.1.1 v9.2.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[CI] DeleteProjectActionTests testSimpleDelete failing
3 participants