Add integration test for deleting struct (#459)

Differentially tests the behavior of deleting a struct with a member
that do not occupy the full 32-byte slot. From [this
issue](https://github.com/paritytech/contract-issues/issues/118) it was
unclear whether the `delete` was expected to reset only the bytes
occupied or the entire slot. The current behavior of resetting the
entire slot is expected.
This commit is contained in:
LJ authored and GitHub committed 2026-01-20 14:34:27 +01:00
1 parent 09625c6310
commit c601377c2d
3 files changed
+50 -7

No files matched your search

+5
View File
@@ -68,6 +68,11 @@ test_spec!(selfdestruct, "Selfdestruct", "Selfdestruct.sol");
test_spec!(clz, "CountLeadingZeros", "CountLeadingZeros.sol");
test_spec!(call_gas, "CallGas", "CallGas.sol");
test_spec!(linker_symbol, "Linked", "Linked.sol");
test_spec!(
struct_delete_storage,
"StructDeleteStorage",
"StructDeleteStorage.sol"
);
fn instantiate(path: &str, contract: &str) -> Vec<SpecsAction> {
vec![Instantiate {