Skip to content
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

Added summary to testing process #215

Merged
merged 1 commit into from
Dec 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
{
"writing-tests-cosmwasm": "CosmWasm",
"writing-tests-sylvia": "Sylvia"
"writing-tests-sylvia": "Sylvia",
"writing-tests-summary": "Summary"
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
---
tags: ["multitest", "getting started", "tests", "summary"]
---

import { Callout, Steps } from "nextra/components";

[App]: ../../app
[AppBuilder]: ../../app-builder

# Summary

To summarize the process of writing tests with **`MultiTest`**, leveraging both pure CosmWasm
libraries and the Sylvia framework, let’s review the general structure of a test. High-quality tests
typically follow a series of common steps to ensure thorough validation and reliability.

By adhering to these structured steps, you can create maintainable and robust test suites that
effectively validate your CosmWasm contracts:

<Steps>
### Initialize the chain

🖝 Set up the blockchain simulator for testing.

### Store contract(s) on chain

🖝 Upload the contract(s) code to the chain.

### Instantiate contract(s)

🖝 Instantiate contract(s) with the desired initial state.

### Interact with contract(s)

🖝 Perform actions such as queries and executes on instantiated contract(s).

### Assert expected results

🖝 Verify the outcomes against expected values to confirm correct behavior.

</Steps>

<Callout>
While the detailed implementation of each step may vary depending on whether you are using pure
CosmWasm libraries or the Sylvia framework — and will also differ based on the specifics of the
test — the overall structure remains consistent, as outlined above.
</Callout>
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
tags: ["multitest", "getting started", "tests", "CosmWasm"]
tags: ["multitest", "getting started", "tests", "Sylvia"]
---

import { Callout, Card, Cards, Steps } from "nextra/components";
Expand Down
Loading