upstream(iota-adapter-transactional-tests): Port upstream miscellaneous chores (lock_file, simtest, tests) - #12691
Open
Dkwcs wants to merge 2 commits into
Conversation
…allet context (#22112)
…lish transactional tests (#22238)
Dkwcs
marked this pull request as ready for review
August 18, 2026 12:43
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
[run-ci]
Description of change
Ports a batch of independent upstream maintenance commits:
WalletContext.--dry-runsupport in the test framework those tests need.Upstream commits
e980dcbf0bbb9a92f77b5e08fabef75b5619bad760e2ea1e68378f177e8168a23399a8a9812d4148Skipped
2c50e39af115d3affddf4e297695a4a91d8e4faftempfileafter version 3.15.0 can pollute the simulator PRNGThe skipped commit replaces
tempfile::tempdir()with a wrapper that keeps the simulator PRNG clean. IOTA already does exactly that viaiota_common::tempdir(), which wrapsnondeterministic!(tempfile::tempdir()), applied repo-wide in #11189 (d49476f37c). All three of its changes are in place:iota-commonis already a dependency ofiota-move-build,BuildConfig::new_for_testingalready callsiota_common::tempdir(), and the directtempfiledependency the patch expects in that crate is already gone.Downstream adaptations
iota-package-management/src/lib.rsupdate_lock_file_for_chain_envtakesresponse: &SuiTransactionBlockResponseupdate_lock_file_with_package_id(IOTA-only, added in #9151 for multi-package publish) already extracts the object ref one layer uporiginal_id: ObjectId, version: u64instead; response extraction stays where downstream already had itiota-package-management/src/lib.rscontext.config.get_active_env(),&env.aliascontext.active_env(),env.alias()(getsetaccessor)iota-package-management/src/lib.rsversion.into()get_new_package_obj_from_responsereturnsObjectReference, not Sui'sObjectReftuple, so version is alreadyu64versionthroughiota-transactional-test-runner/src/args.rsdry_runadded aftergas_priceIotaPublishArgshas an extra downstream field,view_functionsgas_price; attribute taken verbatimiota-transactional-test-runner/src/test_adapter.rsdependencies.extend([MOVE_STDLIB_PACKAGE_ID, IOTA_FRAMEWORK_PACKAGE_ID])dependencies.extend([ObjectId::STD, ObjectId::FRAMEWORK])tests/publish/basic.move.snapfilescargo insta, then compared against the upstream snapshots at60e2ea1eSnapshot differences against upstream fall into three expected categories: line numbers shifted by exactly +1 (extra IOTA licence line), error text rendered as prose downstream where Sui prints the
Debugof the error enum, and differentgas summaryfigures. Task structure, ordering, per-task pass/fail and thecreated/mutated/deletedobject sets all match upstream. The gas amounts the new tests rely on needed no retuning — the balances in the assertions match upstream exactly.For whoever ports the
[pkg-alt]series: upstream has since deletedupdate_lock_fileandupdate_lock_file_for_chain_envoutright, in1a19182f375cc27195e17004d46c711fdeec1ae5[pkg-alt] remove move-package usages. Chasing exact signature parity in this crate buys little, which is why the adaptation above keeps the downstream shape.Links to any relevant issues
Fixes #10837 .
How the change has been tested
Basic tests (linting, compilation, formatting, unit/integration tests)
Patch-specific tests (correctness, functionality coverage)
I have added tests that prove my fix is effective or that my feature works
I have checked that new and existing unit tests pass locally with my changes
cargo nextest run -p iota-adapter-transactional-tests— 324/324 pass, including all five tests touched here.cargo nextest run -p iota-verifier-transactional-tests— 211/211 pass (second consumer of the test runner).cargo check -p iota-graphql-e2e-tests --all-targets— clean (third consumer; running it needs Postgres, so compilation only).cargo check -p iota-package-management,cargo check -p iota --lib— clean; the four existingupdate_lock_filecall sites are unaffected.cargo clippyon both touched crates,cargo +nightly fmt --all,cargo ci-license— clean.Every regenerated snapshot diff was reviewed individually, and additionally compared against the upstream snapshots at
60e2ea1e.