Finschia / cosmwasm

Fast and reusable WebAssembly smart contract runtime(and library) for finschia-sdk.
Apache License 2.0
27 stars 14 forks source link

feat: simplify vm::testing::Contract #181

Closed loloicci closed 2 years ago

loloicci commented 2 years ago

Description

This PR simplifies vm::testing::Contract and makes it not take too much ownership of Backend.

This enables to specify the used querier and APIs in each generating instance from Contract. For example, using https://github.com/line/cosmwasm/pull/180 's update_wasm after constructing a contract needs this PR.

Types of changes

Checklist

loloicci commented 2 years ago

I think it would be good to explain in the this PR body that the purpose is to easily reuse the same db in the PR below.

Thank you @brew0722. The point is not only reusing DB but making instances with specified querier and APIs. I updated the descryption.