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

test: Add retries to increase reliability of test #1319

Merged
merged 6 commits into from
Oct 23, 2023

Conversation

danieljbruce
Copy link
Contributor

@danieljbruce danieljbruce commented Aug 15, 2023

This PR adds retries to the create table function in a test in order to reduce the risk of a flakey test in the case where the table cannot be created. This will solve some of the flakey test issues that we have been having.

Fixes #1292
Fixes #1291

This test needs to be skipped as it is causing P1 issues to appear. We need a formal plan for reproducing this issue.
@danieljbruce danieljbruce requested review from a team as code owners August 15, 2023 17:50
@conventional-commit-lint-gcf
Copy link

conventional-commit-lint-gcf bot commented Aug 15, 2023

🤖 I detect that the PR title and the commit message differ and there's only one commit. To use the PR title for the commit history, you can use Github's automerge feature with squashing, or use automerge label. Good luck human!

-- conventional-commit-lint bot
https://conventionalcommits.org/

@product-auto-label product-auto-label bot added size: xs Pull request size is extra small. api: bigtable Issues related to the googleapis/nodejs-bigtable API. labels Aug 15, 2023
danieljbruce and others added 2 commits August 15, 2023 15:08
This block of code is an after hook that will not work anymore now that the test is skipped because the test creates an instance and the after hook tries to delete it
@@ -85,7 +85,7 @@ describe('Bigtable/Table', () => {
const TABLE = INSTANCE.table('table');

describe('close', () => {
it('should fail when invoking readRows with closed client', async () => {
it.skip('should fail when invoking readRows with closed client', async () => {
Copy link
Contributor

@kolea2 kolea2 Aug 22, 2023

Choose a reason for hiding this comment

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

can we add retries to this test instead? I would prefer not to skip it, unless it is consistently failing (in which case we should investigate an alternate solution there too).

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes. I added a change which will still allow the test to run and retry in the appropriate circumstances.

Add retry options to create table to ensure that there is enough time for the instance to get created in order to avoid flakey tests
@product-auto-label product-auto-label bot added size: s Pull request size is small. and removed size: xs Pull request size is extra small. labels Aug 24, 2023
@danieljbruce danieljbruce changed the title test: Skip a flakey test test: Add retries to increase reliability of test Oct 23, 2023
@danieljbruce danieljbruce added the owlbot:run Add this label to trigger the Owlbot post processor. label Oct 23, 2023
@gcf-owl-bot gcf-owl-bot bot removed the owlbot:run Add this label to trigger the Owlbot post processor. label Oct 23, 2023
@danieljbruce danieljbruce merged commit b4db276 into googleapis:main Oct 23, 2023
15 of 19 checks passed
danieljbruce added a commit to danieljbruce/nodejs-bigtable that referenced this pull request Apr 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api: bigtable Issues related to the googleapis/nodejs-bigtable API. size: s Pull request size is small.
Projects
None yet
2 participants