Skip to content

Commit

Permalink
fix commands & contract version bump
Browse files Browse the repository at this point in the history
  • Loading branch information
killroy192 committed Aug 16, 2024
1 parent 43316f8 commit 9561f7f
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 9 deletions.
2 changes: 2 additions & 0 deletions .github/actions/setup/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ runs:
with:
path: '**/node_modules'
key: ${{ runner.os }}-node_modules-${{ hashFiles('**/package-lock.json') }}
- run: touch .env
shell: bash
- run: make install.ci
shell: bash
if: steps.cache.outputs.cache-hit != 'true'
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/quality-gate.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ jobs:
steps:
- uses: actions/checkout@v4
- uses: ./.github/actions/setup
- run: rm foundry.toml && touch .env
- run: rm foundry.toml
- uses: crytic/[email protected]
id: slither
with:
Expand Down
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ install :; npm i && npx husky
# CI installation
install.ci :; env.add; npm ci

# Update Dependencies
forge.update:; forge update
# Update foundry
foundry.update:; foundryup

# Compile contracts using hardhat
compile :; npx hardhat compile
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion src/Template.sol
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.16;
pragma solidity ^0.8.20;

contract Template {
function hello() external pure returns (string memory) {
Expand Down
7 changes: 4 additions & 3 deletions test/Template.t.sol
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// SPDX-License-Identifier: GPL-3.0

pragma solidity ^0.8.16;
pragma solidity ^0.8.20;

// solhint-disable no-global-import
// solhint-disable no-console
Expand All @@ -16,7 +16,8 @@ contract TemplateTest is Test {
template = new Template();
}

function test_hello() public {
assertEq(template.hello(), "hello world");
function test_hello() public view {
string memory answer = template.hello();
assertEq(answer, "hello world");
}
}

0 comments on commit 9561f7f

Please sign in to comment.