tyk
tyk copied to clipboard
use the same db for gw instance so test doesn't fail randomly
Description
This is required as we have some tests that depends on what other use-cases do in redis. An example of that situation is https://github.com/TykTechnologies/tyk/blob/master/gateway/rpc_test.go#L221 that basically depends on a backup populated by the previous use-case. So, as now we do not use a singleton connection but one singleton per gateway it lead us to randomly failing tests (because they check in different databases)
Related Issue
Motivation and Context
Stabilize MDCB tests
How This Has Been Tested
Version was imported by master branch of dashboard and test always pass
Screenshots (if appropriate)
Types of changes
- [x] Bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing functionality to change)
- [ ] Refactoring or add test (improvements in base code or adds test coverage to functionality)
Checklist
- [x] Make sure you are requesting to pull a topic/feature/bugfix branch (right side). If pulling from your own
fork, don't request your
master
! - [x] Make sure you are making a pull request against the
master
branch (left side). Also, you should start your branch off our latestmaster
. - [ ] My change requires a change to the documentation.
- [ ] If you've changed APIs, describe what needs to be updated in the documentation.
- [ ] If new config option added, ensure that it can be set via ENV variable
- [ ] I have updated the documentation accordingly.
- [ ] Modules and vendor dependencies have been updated; run
go mod tidy && go mod vendor
- [ ] When updating library version must provide reason/explanation for this update.
- [ ] I have added tests to cover my changes.
- [ ] All new and existing tests passed.
- [ ] Check your code additions will not fail linting checks:
- [ ]
go fmt -s
- [ ]
go vet
- [ ]
API tests result: success :white_check_mark:
Branch used: refs/pull/3863/merge
Commit:
Triggered by: pull_request (@sredxny)
Execution page