Skip to content

test: re-enable and fix timed-out unit tests in PublisherImplTest#13180

Open
michaelpri10 wants to merge 2 commits into
googleapis:mainfrom
michaelpri10:pub-impl-test
Open

test: re-enable and fix timed-out unit tests in PublisherImplTest#13180
michaelpri10 wants to merge 2 commits into
googleapis:mainfrom
michaelpri10:pub-impl-test

Conversation

@michaelpri10
Copy link
Copy Markdown
Contributor

Fixes #13051

@michaelpri10 michaelpri10 requested review from a team as code owners May 12, 2026 23:04
Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request re-enables the testResumePublish and testPublishThrowExceptionForUnsubmittedOrderingKeyMessage tests in PublisherImplTest.java which were previously disabled. The testResumePublish test was updated to use a fake executor for the publisher service implementation. Review feedback suggests that testPublishThrowExceptionForUnsubmittedOrderingKeyMessage should also be updated to use the same fake executor configuration to ensure consistency and prevent potential timeout issues.

Comment on lines 598 to 599
Publisher publisher =
getTestPublisherBuilder()
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

medium

The test testResumePublish was updated to include testPublisherServiceImpl.setExecutor(fakeExecutor); to resolve timeout issues. It appears that testPublishThrowExceptionForUnsubmittedOrderingKeyMessage might require a similar configuration to ensure the mock service uses the same fake executor, especially since it is also being re-enabled after previously timing out.

    testPublisherServiceImpl.setExecutor(fakeExecutor);
    Publisher publisher =
        getTestPublisherBuilder()

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.

[java-pubsub] PublisherImplTest is timing out

1 participant