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

Run all tests on CI #21

Merged
merged 2 commits into from
Jun 4, 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
7 changes: 5 additions & 2 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,5 +40,8 @@ jobs:
- name: Clippy
run: make clippy

- name: Integration
run: make test-integration
- name: Test cargo workspace
run: make test-workspace

- name: Test CLI
run: make test-cli
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ install-npm:
format:
cargo fmt --all --check

test: format install test-cli test-workspace
test: format clippy test-cli test-workspace
cargo test --workspace

test-integration: install-bin
Expand Down
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,8 @@ resolc --version

### Development

Please consult the [Makefile](Makefile) targets to learn how to run tests and benchmarks.
Please consult the [Makefile](Makefile) targets to learn how to run tests and benchmarks.
Ensure that your branch passes `make test` locally when submitting a pull request.

## Design overview
`revive` uses [solc](https://github.com/ethereum/solidity/), the Ethereum Solidity compiler, as the [Solidity frontend](crates/solidity/src/lib.rs) to process smart contracts written in Solidity. The YUL IR code (or legacy EVM assembly as a fallback for older `solc` versions) emitted by `solc` is then translated to LLVM IR, targetting a runtime similar to [Polkadots `contracts` pallet](https://docs.rs/pallet-contracts/latest/pallet_contracts/api_doc/trait.Current.html).
6 changes: 3 additions & 3 deletions crates/integration/codesize.json
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
{
"Baseline": 934,
"Computation": 4360,
"DivisionArithmetics": 39448,
"ERC20": 46512,
"DivisionArithmetics": 39824,
"ERC20": 46356,
"Events": 1749,
"FibonacciIterative": 2973,
"Flipper": 3549,
"SHA1": 32709
"SHA1": 32543
}
5 changes: 4 additions & 1 deletion crates/lld-sys/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,10 @@ fn set_rustc_link_flags() {
}

#[cfg(target_os = "linux")]
println!("cargo:rustc-link-lib=dylib=stdc++");
{
println!("cargo:rustc-link-lib=dylib=stdc++");
println!("cargo:rustc-link-lib=tinfo");
}
}

fn main() {
Expand Down