forked from MystenLabs/sui
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[transactional tests] Stabilize fake ID generation (MystenLabs#10382)
## Description - Switched to single gas coin per account, which means a new coin is not generated each transaction - Created a per-task indexing for fake objects, which is what I should have done in the first place ## Test Plan - Rewrote the tests --- If your changes are not user-facing and not a breaking change, you can skip the following section. Otherwise, please indicate what changed, and then add to the Release Notes section as highlighted during the release process. ### Type of Change (Check all that apply) - [ ] user-visible impact - [ ] breaking change for a client SDKs - [ ] breaking change for FNs (FN binary must upgrade) - [ ] breaking change for validators or node operators (must upgrade binaries) - [ ] breaking change for on-chain data layout - [ ] necessitate either a data wipe or data migration ### Release notes
- Loading branch information
Showing
230 changed files
with
1,591 additions
and
1,481 deletions.
There are no files selected for viewing
12 changes: 6 additions & 6 deletions
12
crates/sui-adapter-transactional-tests/tests/call/simple.exp
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 |
---|---|---|
@@ -1,14 +1,14 @@ | ||
processed 4 tasks | ||
|
||
task 1 'publish'. lines 6-28: | ||
created: object(104) | ||
mutated: object(103) | ||
created: object(1,0) | ||
mutated: object(0,0) | ||
|
||
task 2 'run'. lines 30-30: | ||
created: object(106) | ||
mutated: object(105) | ||
created: object(2,0) | ||
mutated: object(0,0) | ||
|
||
task 3 'view-object'. lines 32-32: | ||
Owner: Account Address ( A ) | ||
Version: 2 | ||
Contents: Test::M1::Object {id: sui::object::UID {id: sui::object::ID {bytes: fake(106)}}, value: 0u64} | ||
Version: 3 | ||
Contents: Test::M1::Object {id: sui::object::UID {id: sui::object::ID {bytes: fake(2,0)}}, value: 0u64} |
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 |
---|---|---|
|
@@ -29,4 +29,4 @@ module Test::M1 { | |
|
||
//# run Test::M1::create --args 0 @A | ||
|
||
//# view-object 106 | ||
//# view-object 2,0 |
8 changes: 4 additions & 4 deletions
8
crates/sui-adapter-transactional-tests/tests/checkpoint/clock.exp
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 |
---|---|---|
@@ -1,17 +1,17 @@ | ||
processed 5 tasks | ||
|
||
task 1 'consensus-commit-prologue'. lines 6-6: | ||
mutated: 0x6 | ||
mutated: 0x0000000000000000000000000000000000000000000000000000000000000006 | ||
|
||
task 2 'view-object'. lines 8-8: | ||
Owner: Shared | ||
Version: 2 | ||
Contents: sui::clock::Clock {id: sui::object::UID {id: sui::object::ID {bytes: 0x6}}, timestamp_ms: 43u64} | ||
Contents: sui::clock::Clock {id: sui::object::UID {id: sui::object::ID {bytes: 0x0000000000000000000000000000000000000000000000000000000000000006}}, timestamp_ms: 43u64} | ||
|
||
task 3 'consensus-commit-prologue'. lines 10-10: | ||
mutated: 0x6 | ||
mutated: 0x0000000000000000000000000000000000000000000000000000000000000006 | ||
|
||
task 4 'view-object'. lines 12-12: | ||
Owner: Shared | ||
Version: 3 | ||
Contents: sui::clock::Clock {id: sui::object::UID {id: sui::object::ID {bytes: 0x6}}, timestamp_ms: 45u64} | ||
Contents: sui::clock::Clock {id: sui::object::UID {id: sui::object::ID {bytes: 0x0000000000000000000000000000000000000000000000000000000000000006}}, timestamp_ms: 45u64} |
62 changes: 31 additions & 31 deletions
62
crates/sui-adapter-transactional-tests/tests/child_count/count_decremented.exp
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 |
---|---|---|
@@ -1,74 +1,74 @@ | ||
processed 17 tasks | ||
|
||
init: | ||
A: object(103), B: object(104) | ||
A: object(0,0), B: object(0,1) | ||
|
||
task 1 'publish'. lines 9-52: | ||
created: object(106) | ||
mutated: object(105) | ||
created: object(1,0) | ||
mutated: object(0,2) | ||
|
||
task 2 'run'. lines 54-54: | ||
created: object(108) | ||
mutated: object(107) | ||
created: object(2,0) | ||
mutated: object(0,0) | ||
|
||
task 3 'view-object'. lines 56-56: | ||
Owner: Account Address ( A ) | ||
Version: 2 | ||
Contents: test::m::S {id: sui::object::UID {id: sui::object::ID {bytes: fake(108)}}} | ||
Contents: test::m::S {id: sui::object::UID {id: sui::object::ID {bytes: fake(2,0)}}} | ||
|
||
task 4 'run'. lines 58-58: | ||
created: object(110), object(111) | ||
mutated: object(108), object(109) | ||
created: object(4,0), object(4,1) | ||
mutated: object(0,0), object(2,0) | ||
|
||
task 5 'run'. lines 60-60: | ||
mutated: object(108), object(112) | ||
deleted: object(110), object(111) | ||
mutated: object(0,0), object(2,0) | ||
deleted: object(4,0), object(4,1) | ||
|
||
task 6 'view-object'. lines 62-66: | ||
Owner: Account Address ( A ) | ||
Version: 4 | ||
Contents: test::m::S {id: sui::object::UID {id: sui::object::ID {bytes: fake(108)}}} | ||
Contents: test::m::S {id: sui::object::UID {id: sui::object::ID {bytes: fake(2,0)}}} | ||
|
||
task 7 'run'. lines 68-68: | ||
created: object(114) | ||
mutated: object(113) | ||
created: object(7,0) | ||
mutated: object(0,0) | ||
|
||
task 8 'view-object'. lines 70-70: | ||
Owner: Account Address ( A ) | ||
Version: 2 | ||
Contents: test::m::S {id: sui::object::UID {id: sui::object::ID {bytes: fake(114)}}} | ||
Version: 5 | ||
Contents: test::m::S {id: sui::object::UID {id: sui::object::ID {bytes: fake(7,0)}}} | ||
|
||
task 9 'run'. lines 72-72: | ||
created: object(116), object(117) | ||
mutated: object(114), object(115) | ||
created: object(9,0), object(9,1) | ||
mutated: object(0,0), object(7,0) | ||
|
||
task 10 'run'. lines 74-74: | ||
mutated: object(114), object(116), object(117), object(118) | ||
mutated: object(0,0), object(7,0), object(9,0), object(9,1) | ||
|
||
task 11 'view-object'. lines 76-80: | ||
Owner: Account Address ( A ) | ||
Version: 4 | ||
Contents: test::m::S {id: sui::object::UID {id: sui::object::ID {bytes: fake(114)}}} | ||
Version: 7 | ||
Contents: test::m::S {id: sui::object::UID {id: sui::object::ID {bytes: fake(7,0)}}} | ||
|
||
task 12 'run'. lines 82-82: | ||
created: object(120) | ||
mutated: object(119) | ||
created: object(12,0) | ||
mutated: object(0,0) | ||
|
||
task 13 'view-object'. lines 84-84: | ||
Owner: Account Address ( A ) | ||
Version: 2 | ||
Contents: test::m::S {id: sui::object::UID {id: sui::object::ID {bytes: fake(120)}}} | ||
Version: 8 | ||
Contents: test::m::S {id: sui::object::UID {id: sui::object::ID {bytes: fake(12,0)}}} | ||
|
||
task 14 'run'. lines 86-86: | ||
created: object(122), object(123) | ||
mutated: object(120), object(121) | ||
created: object(14,0), object(14,1) | ||
mutated: object(0,0), object(12,0) | ||
|
||
task 15 'run'. lines 88-88: | ||
created: object(125) | ||
mutated: object(120), object(122), object(124) | ||
wrapped: object(123) | ||
created: object(15,0) | ||
mutated: object(0,0), object(12,0), object(14,0) | ||
wrapped: object(14,1) | ||
|
||
task 16 'view-object'. lines 90-90: | ||
Owner: Account Address ( A ) | ||
Version: 4 | ||
Contents: test::m::S {id: sui::object::UID {id: sui::object::ID {bytes: fake(120)}}} | ||
Version: 10 | ||
Contents: test::m::S {id: sui::object::UID {id: sui::object::ID {bytes: fake(12,0)}}} |
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
22 changes: 11 additions & 11 deletions
22
crates/sui-adapter-transactional-tests/tests/child_count/delete_by_wrap.exp
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 |
---|---|---|
@@ -1,26 +1,26 @@ | ||
processed 6 tasks | ||
|
||
init: | ||
A: object(103), B: object(104) | ||
A: object(0,0), B: object(0,1) | ||
|
||
task 1 'publish'. lines 9-38: | ||
created: object(106) | ||
mutated: object(105) | ||
created: object(1,0) | ||
mutated: object(0,2) | ||
|
||
task 2 'run'. lines 40-40: | ||
created: object(108) | ||
mutated: object(107) | ||
created: object(2,0) | ||
mutated: object(0,0) | ||
|
||
task 3 'run'. lines 42-42: | ||
created: object(110), object(111) | ||
mutated: object(108), object(109) | ||
created: object(3,0), object(3,1) | ||
mutated: object(0,0), object(2,0) | ||
|
||
task 4 'view-object'. lines 44-44: | ||
Owner: Account Address ( A ) | ||
Version: 3 | ||
Contents: test::m::S {id: sui::object::UID {id: sui::object::ID {bytes: fake(108)}}} | ||
Contents: test::m::S {id: sui::object::UID {id: sui::object::ID {bytes: fake(2,0)}}} | ||
|
||
task 5 'run'. lines 46-46: | ||
created: object(113) | ||
mutated: object(112) | ||
wrapped: object(108) | ||
created: object(5,0) | ||
mutated: object(0,0) | ||
wrapped: object(2,0) |
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
10 changes: 5 additions & 5 deletions
10
crates/sui-adapter-transactional-tests/tests/child_count/delete_by_wrap_one_txn.exp
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 |
---|---|---|
@@ -1,12 +1,12 @@ | ||
processed 3 tasks | ||
|
||
init: | ||
A: object(103), B: object(104) | ||
A: object(0,0), B: object(0,1) | ||
|
||
task 1 'publish'. lines 9-32: | ||
created: object(106) | ||
mutated: object(105) | ||
created: object(1,0) | ||
mutated: object(0,2) | ||
|
||
task 2 'run'. lines 34-34: | ||
created: object(108), object(109), object(110) | ||
mutated: object(107) | ||
created: object(2,0), object(2,1), object(2,2) | ||
mutated: object(0,0) |
20 changes: 10 additions & 10 deletions
20
crates/sui-adapter-transactional-tests/tests/child_count/delete_parent_invalid.exp
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 |
---|---|---|
@@ -1,25 +1,25 @@ | ||
processed 6 tasks | ||
|
||
init: | ||
A: object(103), B: object(104) | ||
A: object(0,0), B: object(0,1) | ||
|
||
task 1 'publish'. lines 9-33: | ||
created: object(106) | ||
mutated: object(105) | ||
created: object(1,0) | ||
mutated: object(0,2) | ||
|
||
task 2 'run'. lines 35-35: | ||
created: object(108) | ||
mutated: object(107) | ||
created: object(2,0) | ||
mutated: object(0,0) | ||
|
||
task 3 'run'. lines 37-37: | ||
created: object(110), object(111) | ||
mutated: object(108), object(109) | ||
created: object(3,0), object(3,1) | ||
mutated: object(0,0), object(2,0) | ||
|
||
task 4 'view-object'. lines 39-39: | ||
Owner: Account Address ( A ) | ||
Version: 3 | ||
Contents: test::m::S {id: sui::object::UID {id: sui::object::ID {bytes: fake(108)}}} | ||
Contents: test::m::S {id: sui::object::UID {id: sui::object::ID {bytes: fake(2,0)}}} | ||
|
||
task 5 'run'. lines 41-41: | ||
mutated: object(112) | ||
deleted: object(108) | ||
mutated: object(0,0) | ||
deleted: object(2,0) |
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
24 changes: 12 additions & 12 deletions
24
crates/sui-adapter-transactional-tests/tests/child_count/delete_parent_valid.exp
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 |
---|---|---|
@@ -1,29 +1,29 @@ | ||
processed 7 tasks | ||
|
||
init: | ||
A: object(103), B: object(104) | ||
A: object(0,0), B: object(0,1) | ||
|
||
task 1 'publish'. lines 9-58: | ||
created: object(106) | ||
mutated: object(105) | ||
created: object(1,0) | ||
mutated: object(0,2) | ||
|
||
task 2 'run'. lines 59-59: | ||
created: object(108) | ||
mutated: object(107) | ||
created: object(2,0) | ||
mutated: object(0,0) | ||
|
||
task 3 'run'. lines 61-61: | ||
created: object(110), object(111) | ||
mutated: object(108), object(109) | ||
created: object(3,0), object(3,1) | ||
mutated: object(0,0), object(2,0) | ||
|
||
task 4 'view-object'. lines 63-63: | ||
Owner: Account Address ( A ) | ||
Version: 3 | ||
Contents: test::m::S {id: sui::object::UID {id: sui::object::ID {bytes: fake(108)}}} | ||
Contents: test::m::S {id: sui::object::UID {id: sui::object::ID {bytes: fake(2,0)}}} | ||
|
||
task 5 'run'. lines 65-65: | ||
mutated: object(108), object(112) | ||
deleted: object(110), object(111) | ||
mutated: object(0,0), object(2,0) | ||
deleted: object(3,0), object(3,1) | ||
|
||
task 6 'run'. lines 67-67: | ||
mutated: object(113) | ||
deleted: object(108) | ||
mutated: object(0,0) | ||
deleted: object(2,0) |
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
Oops, something went wrong.