Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/tasinco/avalanche-test-tool
Ethereum testing tool.
https://github.com/tasinco/avalanche-test-tool
avalanche ethereum ethereum-contract evm go golang solidity web3
Last synced: 10 days ago
JSON representation
Ethereum testing tool.
- Host: GitHub
- URL: https://github.com/tasinco/avalanche-test-tool
- Owner: tasinco
- License: apache-2.0
- Created: 2023-07-20T12:52:01.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2023-07-23T15:20:54.000Z (over 1 year ago)
- Last Synced: 2024-12-01T16:47:00.171Z (2 months ago)
- Topics: avalanche, ethereum, ethereum-contract, evm, go, golang, solidity, web3
- Language: Go
- Homepage:
- Size: 94.7 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# ava-test-tool
Start a local net 5 node Avalanche testing environment.
Deploy and test solidity contracts on a live local EVM.
## Howto run
```shell
go run ./cmd/app/
```## Howto connect
You can interact with the C chain at http://localhost:9650
```go
package mainimport (
"context"
"github.com/ethereum/go-ethereum/ethclient"
"github.com/ethereum/go-ethereum/rpc"
"log"
)func main() {
ctx := context.Background()rpcClnt, err := rpc.Dial("http://localhost:9650/ext/bc/C/rpc")
if err != nil {
log.Fatal(err)
}
ethClnt := ethclient.NewClient(rpcClnt)chainID, err := ethClnt.ChainID(ctx)
if err != nil {
log.Fatal(err)
}log.Println(chainID)
}
```## Test deploy
[revertdeploy](reverterdeploy) deploys the reverted contract and test some calls.