-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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
[backport -> release/3.6.x] tests: fix flakiness #12581
Conversation
Cherry-pick failed for |
Cherry-pick failed for Please cherry-pick the changes locally. git remote add upstream https://github.com/kong/kong-ee
git fetch upstream release/3.6.x
git worktree add -d .worktree/cherry-pick-12581-to-release/3.6.x-to-upstream upstream/release/3.6.x
cd .worktree/cherry-pick-12581-to-release/3.6.x-to-upstream
git checkout -b cherry-pick-12581-to-release/3.6.x-to-upstream
ancref=$(git merge-base 510b137268703dece7d0f1a00a439375d2ff9311 0f23b74b8e04a656ab1bfa4bc90efc17f0579583)
git cherry-pick -x $ancref..0f23b74b8e04a656ab1bfa4bc90efc17f0579583 |
I don't feel it is correct to cherry-pick a backporting PR. Is this intended? |
I am not sure, but I will cherry-pick and then backport to EE |
Automated backport to
release/3.6.x
, triggered by a label in #12580.Original description
Please REBASE and MERGE
Summary
The dynamic test scheduler exposed some issues by disrupting the order of the tests, some of which did not initialize the database or wrote incompatible data to the database, causing the Gateway instance to fail to start and causing the following test to fail.
Starting a Gateway instance even if it's not needed
spec/03-plugins/39-ai-request-transformer/01-transformer_spec.lua
spec/03-plugins/40-ai-response-transformer/01-transformer_spec.lua
These two test sets start a Gateway instance to launch a mocking server, which can be replaced by the
spec.helpers.http_mock
.The database was not initialized before starting the Gateway instance
spec/02-integration/09-hybrid_mode/02-start_stop_spec.lua
Starting a service using a fixed port instead of a random port
Since the test sequence is disrupted and the port release is not real-time, this may cause the port to be occupied to the point where the test fails.
Checklist
changelog/unreleased/kong
orskip-changelog
label added on PR if changelog is unnecessary. README.mdIssue reference
KAG-3746