-
Notifications
You must be signed in to change notification settings - Fork 836
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
feat (tests): enable multiple upgrades for automated upgrade tests #1283
Conversation
ENG-1388 Adjust Upgrade Test Suite to allow for upgrading a series of more than two upgrades
Currently only one-step upgrades are possible (e.g. v10.0.1 > v11.0.0-rc1). In order to test certain cases regarding testnet upgrades it would be necessary to replicate multi-step upgrades. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
tACK. Great work on this @MalteHerrmann this will really simplify upgrade testing!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
tACK! Great work!! Left a small typo fix.
Also, I noted that running the make test-upgrade
command runs all the tests on the e2e package. Not sure if this is intended, but refactoring the test-upgrade
instruction on the Makefile to this (only last line changes) only runs the automated upgrade test and shows the logs of the upgrade on real time (at least for me, using Ubuntu)
test-upgrade:
mkdir -p ./build
rm -rf build/.evmosd
INITIAL_VERSION=$(INITIAL_VERSION) TARGET_VERSION=$(TARGET_VERSION) \
E2E_SKIP_CLEANUP=$(E2E_SKIP_CLEANUP) MOUNT_PATH=$(MOUNT_PATH) CHAIN_ID=$(CHAIN_ID) \
go test ./tests/e2e -v -run ^TestIntegrationTestSuite$
Another nice-to-have would be to extend this functionality to any number of upgrades. For example, I would replace INITIAL_VERSION and TARGET_VERSION with VERSION_SEQUENCE.
VERSION_SEQUENCE=<initial_version>/<1st_upgrade_version>/<2nd_upgrade_version>/<target_version>
But this is not a priority right now, and I understand the refactor would take some time. Just mentioning as a nice-to-have
Co-authored-by: Tomas Guerra <54514587+GAtom22@users.noreply.github.com>
@GAtom22 it is already possible to include any number of upgrades, they just have to be separated by a forward slash - so e.g. I also thought about refactoring the variables to an upgrade sequence but saw the advantage with keeping the target version separate. The advantage is that users can just leave it empty and know the local codebase is used and don’t have to remember the exact syntax e.g. to put What do you think? |
Codecov Report
Additional details and impacted files@@ Coverage Diff @@
## main #1283 +/- ##
==========================================
- Coverage 76.28% 73.48% -2.81%
==========================================
Files 149 153 +4
Lines 8304 8639 +335
==========================================
+ Hits 6335 6348 +13
- Misses 1775 2095 +320
- Partials 194 196 +2
|
Description
This PR does the following
submit-legacy-proposal
command (Evmos < v10.0.0)In order to run a sequence of version A to version B to version C, the syntax is as follows:
The following commands can be tested (checkbox indicates if they work as expected):
make test-upgrade INITIAL_VERSION=v10.0.1
make test-upgrade INITIAL_VERSION=v10.0.1 TARGET_VERSION=v11.0.0-rc3
make test-upgrade INITIAL_VERSION=v10.0.1/v11.0.0-rc1 TARGET_VERSION=v11.0.0-rc3
Closes ENG-1388