https://github.com/jamiew/webring3-new
Rebuild of webring3 using latest forge templates
https://github.com/jamiew/webring3-new
Last synced: about 1 year ago
JSON representation
Rebuild of webring3 using latest forge templates
- Host: GitHub
- URL: https://github.com/jamiew/webring3-new
- Owner: jamiew
- License: unlicense
- Created: 2022-09-26T02:43:26.000Z (almost 4 years ago)
- Default Branch: master
- Last Pushed: 2022-09-26T02:43:28.000Z (almost 4 years ago)
- Last Synced: 2025-06-19T03:48:24.858Z (about 1 year ago)
- Language: Solidity
- Size: 1000 Bytes
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
#
Forge Template
**Template repository for getting started quickly with Foundry projects**

## Getting Started
Click "Use this template" on [GitHub](https://github.com/foundry-rs/forge-template) to create a new repository with this repo as the initial state.
Or, if your repo already exists, run:
```sh
forge init
forge build
forge test
```
## Writing your first test
All you need is to `import forge-std/Test.sol` and then inherit it from your test contract. Forge-std's Test contract comes with a pre-instatiated [cheatcodes environment](https://book.getfoundry.sh/cheatcodes/), the `vm`. It also has support for [ds-test](https://book.getfoundry.sh/reference/ds-test.html)-style logs and assertions. Finally, it supports Hardhat's [console.log](https://github.com/brockelmore/forge-std/blob/master/src/console.sol). The logging functionalities require `-vvvv`.
```solidity
pragma solidity 0.8.10;
import "forge-std/Test.sol";
contract ContractTest is Test {
function testExample() public {
vm.roll(100);
console.log(1);
emit log("hi");
assertTrue(true);
}
}
```
## Development
This project uses [Foundry](https://getfoundry.sh). See the [book](https://book.getfoundry.sh/getting-started/installation.html) for instructions on how to install and use Foundry.