-
Notifications
You must be signed in to change notification settings - Fork 134
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: Replace difftest model with Quint=>MBT #1369
Merged
Merged
Changes from all commits
Commits
Show all changes
117 commits
Select commit
Hold shift + click to select a range
a4840fc
Start adding mbt using Quint model
p-offtermatt 5ffe647
Clean up dependencies
p-offtermatt 5f96643
Start taking difftest code for mbt
p-offtermatt 2285a4c
Implement chain startup
p-offtermatt ae5b106
Rewrite chain startup
p-offtermatt 50231fb
Continue chain setup
p-offtermatt 2d29208
Add trusting period
p-offtermatt 81bcd3b
Adjust tests for fee testing
p-offtermatt eedcf46
Use correct validators in RequestInitChain
p-offtermatt 1bb6ed0
Remove min and max functions
p-offtermatt 065f458
Add type annotations
p-offtermatt b1fde43
Make state printing more robust
p-offtermatt 44914e2
Fix setting default power reduction
p-offtermatt e9d7107
Adjust max steps and run all tests
p-offtermatt b8640d9
Change semantics of VotingPowerChange to take change amount, not new …
p-offtermatt a8f45c4
Adjust voting power choices to be changes instead of absolute values
p-offtermatt ef7a80e
Start refactoring relaying code
p-offtermatt 6336273
Refactor map to list of pairs
p-offtermatt dd9d878
Add libraries for map rewrite
p-offtermatt 61b6a85
Start fixing client updates
p-offtermatt abc12cf
Add ccv_happy module as a happyPath variant
p-offtermatt ad25029
Fix model: packets are emitted based on the timestamp of the last blo…
p-offtermatt fea71dc
Add viewer for ModelState and fix model-system equivalence checks
p-offtermatt 8f8d2c4
Add type annotations
p-offtermatt 6dacc09
Add ack delivery after each step
p-offtermatt 2c3a6d5
Add programmatic ways of generating traces
p-offtermatt 71a3b80
Make invariant optional
p-offtermatt c510e61
Pretty up the output
p-offtermatt db16905
Add script for generating happy and normal traces
p-offtermatt 436aec4
Remove message sends for consumers that were started in this block
p-offtermatt 5d17552
Use .itf extension instead of .json
p-offtermatt d085cce
Start adjusting behaviour for started/stopped consumers
p-offtermatt 3a7564e
Use GetEmptyProtocolState instead of verbose declaration
p-offtermatt 1b8ae7b
Add expired status and set timestamps of new consumers
p-offtermatt c7cba8b
Add note to split up timestamps
p-offtermatt 2d130df
Advance MBT prototype
p-offtermatt 8f31705
Add test case for expired clients
p-offtermatt 8681895
Adjust tests for new timestamp handling
p-offtermatt f229db7
Use -1 as last timestamp when no block was comitted
p-offtermatt 8bbb86a
Fix client expiration conditions
p-offtermatt 9237c34
Start writing model with boundeddrift
p-offtermatt 2b9873a
Add model with bounded drift
p-offtermatt dd2cd7c
Rename module to match filename
p-offtermatt 603a668
Add extra log output and trace gen scripts
p-offtermatt 719614c
Add Apalache output folder to gitignore
p-offtermatt 468dc7f
Remove expired clients
p-offtermatt 31bd231
Remove different time offsets for different chains
p-offtermatt 76dcc15
Fix timestamp
p-offtermatt 3286e09
Fix error where we would choose nondet from empty sets
p-offtermatt 1433ee4
Add timeout timestamps to packets
p-offtermatt 0f8228d
Adapt tests to the empty-validator-power behaviour
p-offtermatt 6887906
Adjust timeout test
p-offtermatt ab1430a
Add logic for comparing timestamps of packets
p-offtermatt dbbe2b0
Fix: VSCTimeout is based on EndBlocj
p-offtermatt 680f3c4
Add logic for timed out vsc packets
p-offtermatt 4238978
Fix vsc timeouts should happen during endblock
p-offtermatt 2d1a874
Revert the timestamp change
p-offtermatt bcdd85c
Add more diverse traces
p-offtermatt eacfd87
Fix acct sequences not incrementing when messages error ot
p-offtermatt 33de97b
Move from difference folder to mbt folder
p-offtermatt 0e584c3
Add back consumer chain stopping
p-offtermatt 95e5253
Disallow empty validator sets
p-offtermatt d272b73
Add README and generate fewer traces
p-offtermatt 5dcf517
merge in main
p-offtermatt 684a2e5
Remove difftest link from old docs
p-offtermatt 703e462
Fix merge conflicts
p-offtermatt b8db7bc
Revert changes to e2e tests
p-offtermatt ce62ab0
Fix link to MBT
p-offtermatt 7eeb540
Tidy go mod and use go 1.20
p-offtermatt 2a9c39b
Start linting
p-offtermatt b533d1f
Lint files
p-offtermatt 4c205f6
Add nolint instruction from main
p-offtermatt 4c74bcb
Do not check for errors for consumer chain stopping
p-offtermatt fc48575
Add mbt to makefile and CI
p-offtermatt 680b9df
Move reference to difftests into reference to MBT
p-offtermatt 10ced0a
Remove cache npm
p-offtermatt 8bce148
Fix test-mbt-cov Make instructions
p-offtermatt d00a1cc
Generate less traces and fix path for testing
p-offtermatt df7ea65
Fix test path
p-offtermatt 6b99c02
Archive traces in workflow
p-offtermatt e2ee8a2
Add long version of MBT to makefile
p-offtermatt 0ac3c8a
Use variable instead of true to better signal semantics
p-offtermatt db9a697
Update testutil/simibc/chain_util.go
p-offtermatt bf2d8d5
Address comments
p-offtermatt 064188e
Merge branch 'main' into ph/mbt
p-offtermatt d689142
Add punctuation remoced due to main merge
p-offtermatt e730ebf
Remove outdated doc line
p-offtermatt d103bda
Add Quint tests to CI
p-offtermatt 5d97774
Update tests/mbt/model/ccv_model.qnt
p-offtermatt 5fecff1
Address comments
p-offtermatt 90acddc
Add zero check to VotingPowerChangeToEmptyTest
p-offtermatt 1798924
Incorporate Karolos' comments
p-offtermatt 30a79ad
Add spacing between jobs
p-offtermatt 2396038
Update tests/mbt/model/ccv_model.qnt
p-offtermatt 1659892
Address comments
p-offtermatt 21813de
Remove 4 week time advancement
p-offtermatt a3df827
Upload traces even when test fails
p-offtermatt e52d186
Fix condition for trace archival
p-offtermatt b74a09f
Remove unused index
p-offtermatt e039ef9
Remove outdated for loop
p-offtermatt b13ead1
Fix if condition for trace upload
p-offtermatt e7807bf
Add comment about timestamps
p-offtermatt a052b21
Remove long time advancements
p-offtermatt 60589a1
Address comments
p-offtermatt 82ca137
Make comment clearer
p-offtermatt 6d68920
Update tests/mbt/driver/generate_traces.sh
p-offtermatt 49ba056
Update tests/mbt/run_invariants.sh
p-offtermatt d04e140
Update tests/mbt/driver/README.md
p-offtermatt f5f5d6e
Merge branch 'main' into ph/mbt
p-offtermatt 4af62df
Merge branch 'main' into ph/mbt
p-offtermatt d01e561
Update testutil/simibc/relayed_path.go
p-offtermatt 2a1db2b
Update tests/mbt/driver/generate_more_traces.sh
p-offtermatt 2488377
Remove difftest folder
p-offtermatt 357541f
Merge branch 'ph/mbt' of https://github.com/cosmos/interchain-securit…
p-offtermatt 73ba96f
Minor fixes based on PR comments
p-offtermatt 44e6145
Make timedout status a const
p-offtermatt 7940d0f
Lengthen retention to 6 days
p-offtermatt File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -90,7 +90,7 @@ jobs: | |
name: "${{ github.sha }}-integration-coverage" | ||
path: ./integration-profile.out | ||
|
||
test-difference: | ||
test-mbt: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
|
@@ -100,6 +100,11 @@ jobs: | |
check-latest: true | ||
cache: true | ||
cache-dependency-path: go.sum | ||
- uses: actions/setup-node@v4 | ||
with: | ||
node-version: ">= 18" | ||
check-latest: true | ||
- run: npm i @informalsystems/quint -g | ||
- uses: technote-space/[email protected] | ||
id: git_diff | ||
with: | ||
|
@@ -111,19 +116,26 @@ jobs: | |
**/go.sum | ||
**/Makefile | ||
Makefile | ||
- name: difference tests | ||
- name: mbt tests | ||
if: env.GIT_DIFF | ||
run: | | ||
make test-difference-cov | ||
make test-mbt-cov | ||
- uses: actions/upload-artifact@v3 | ||
if: env.GIT_DIFF | ||
with: | ||
name: "${{ github.sha }}-difference-coverage" | ||
path: ./difference-profile.out | ||
|
||
name: "${{ github.sha }}-mbt-coverage" | ||
path: ./mbt-profile.out | ||
- name: Archive MBT traces | ||
uses: actions/upload-artifact@v3 | ||
if: ${{ success() || failure() }} # to upload the traces only when the test failed | ||
with: | ||
name: mbt-traces | ||
path: tests/mbt/driver/traces | ||
retention-days: 6 # to not clog our cloud storage too much, we retain only for a few days | ||
|
||
repo-analysis: | ||
runs-on: ubuntu-latest | ||
needs: [tests, test-integration, test-difference] | ||
needs: [tests, test-integration, test-mbt] | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: technote-space/[email protected] | ||
|
@@ -146,7 +158,7 @@ jobs: | |
- uses: actions/download-artifact@v3 | ||
if: env.GIT_DIFF | ||
with: | ||
name: "${{ github.sha }}-difference-coverage" | ||
name: "${{ github.sha }}-mbt-coverage" | ||
continue-on-error: true | ||
- name: sonarcloud | ||
if: ${{ env.GIT_DIFF && !github.event.pull_request.draft }} | ||
|
@@ -243,4 +255,26 @@ jobs: | |
- name: trace-e2e tests | ||
if: env.GIT_DIFF | ||
run: | | ||
run: make test-trace | ||
make test-trace | ||
model-analysis: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
lfs: true | ||
- name: checkout LFS objects | ||
run: git lfs checkout | ||
- uses: actions/setup-node@v4 | ||
with: | ||
node-version: ">= 18" | ||
check-latest: true | ||
- run: npm i @informalsystems/quint -g | ||
- uses: technote-space/[email protected] | ||
id: git_diff | ||
with: | ||
PATTERNS: | | ||
tests/mbt/model/**.qnt | ||
- name: verify the Quint model | ||
if: env.GIT_DIFF | ||
run: | | ||
make verify-models |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
I changed the signature of the CreateValidators function to better suit my needs, so I had to adjust this here