-
Notifications
You must be signed in to change notification settings - Fork 133
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
docs: deprecation warnings for clarinet test and clarinet run (#1157)
* docs: deprecation warning for clarinet test and clarinet run * docs: fix typo * docs: typo
- Loading branch information
1 parent
17d2058
commit edf98aa
Showing
3 changed files
with
26 additions
and
38 deletions.
There are no files selected for viewing
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 |
---|---|---|
|
@@ -351,6 +351,8 @@ This annotation tells the check-checker to consider the specified variables to b | |
|
||
### Execute a test suite | ||
|
||
> Warning: `clarinet test` will soon be deprecated in favor of a new way of testing smart contracts. The new documentation is under construction. In the meantime, learn more [in the clarinet-sdk Readme](https://github.com/hirosystems/clarinet/blob/01da3550670f321a2f19fd3b0f8df0fb4b769b08/components/clarinet-sdk/README.md). | ||
Clarinet provides a testing harness based on Deno that can enable you to create automated unit tests or pseudo-integration tests using Typescript. | ||
|
||
```bash | ||
|
@@ -396,10 +398,10 @@ open coverage/index.html | |
Clarinet can also be used to optimize costs. When executing a test suite, Clarinet will keep track of all the costs being computed when executing the `contract-call`, and display the most expensive ones in a table: | ||
|
||
```bash | ||
clarinet test --cost | ||
clarinet test --costs | ||
``` | ||
|
||
The `--cost` option can be used in conjunction with `--watch` and filters to maximize productivity, as illustrated here: | ||
The `--costs` option can be used in conjunction with `--watch` and filters to maximize productivity, as illustrated here: | ||
|
||
![costs](docs/images/costs.gif) | ||
|
||
|
@@ -601,27 +603,6 @@ You may also add the steps above in your existing workflows. The generated code | |
|
||
For more information on how you can use GitHub Actions with Clarinet, please see the [A Simple CI With Clarinet and GitHub](https://www.youtube.com/watch?v=cEv6Mi4EcKQ&list=PL5Ujm489LoJaAz9kUJm8lYUWdGJ2AnQTb&index=8) YouTube video | ||
|
||
### Extensions | ||
|
||
Clarinet can easily be extended by community members: open source contributions to Clarinet are welcome, but you may also write your own Clarinet extensions if you want to integrate Clarity contracts with your own tooling and workflow. | ||
|
||
| Name | wallet access | disk write | disk read | Deployment | Description | | ||
| ------------------------- | ------------- | ---------- | --------- | --------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | | ||
| stacksjs-helper-generator | no | yes | no | https://deno.land/x/[email protected]/ext/stacksjs-helper-generator.ts | Facilitates contract integration by generating some typescript constants that can be used with stacks.js. Never hard code a stacks address again! | | ||
| | | | | | | ||
|
||
#### How to use extensions | ||
|
||
Extensions are run with the following syntax: | ||
|
||
``` | ||
clarinet run --allow-write https://deno.land/x/[email protected]/ext/stacksjs-helper-generator.ts | ||
``` | ||
|
||
An extension can be deployed as a standalone plugin on Deno, or may also be a local file if it includes sensitive / private setup informations. | ||
|
||
As illustrated in the example above, permissions (wallet / disk read / disk write) are declared using command flags. If at runtime, the Clarinet extension is trying to write to disk, read disk, or access wallets without permission, the script will fail. | ||
|
||
### Debug your contracts | ||
|
||
#### VS Code Debugger | ||
|
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
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