-
Notifications
You must be signed in to change notification settings - Fork 226
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
added unit test and integration test.
- Loading branch information
1 parent
ff8f788
commit 46d08d1
Showing
1,244 changed files
with
485,723 additions
and
37 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 |
---|---|---|
@@ -1,42 +1,64 @@ | ||
[package] | ||
name = "solang" | ||
version = "0.3.3" | ||
authors = ["Sean Young <[email protected]>", "Lucas Steuernagel <[email protected]>", "Cyrill Leutwiler <[email protected]>"] | ||
authors = [ | ||
"Sean Young <[email protected]>", | ||
"Lucas Steuernagel <[email protected]>", | ||
"Cyrill Leutwiler <[email protected]>", | ||
] | ||
repository = "https://github.com/hyperledger-solang/solang" | ||
documentation = "https://solang.readthedocs.io/" | ||
license = "Apache-2.0" | ||
build = "build.rs" | ||
description = "Solang Solidity Compiler" | ||
keywords = [ "solidity", "compiler", "solana", "polkadot", "substrate" ] | ||
keywords = ["solidity", "compiler", "solana", "polkadot", "substrate"] | ||
rust-version = "1.81.0" | ||
edition = "2021" | ||
exclude = [ "/.*", "/docs", "/examples", "/solana-library", "/tests", "/integration", "/vscode", "/testdata" ] | ||
exclude = [ | ||
"/.*", | ||
"/docs", | ||
"/examples", | ||
"/solana-library", | ||
"/tests", | ||
"/integration", | ||
"/vscode", | ||
"/testdata", | ||
] | ||
|
||
[build-dependencies] | ||
cc = "1.0" | ||
|
||
[dependencies] | ||
llvm-sys = "160.0" | ||
regex = "1" | ||
rand = "0.8" | ||
num-bigint = { version = "0.4", features = ["rand"]} | ||
num-bigint = { version = "0.4", features = ["rand"] } | ||
num-traits = "0.2" | ||
num-integer = "0.1" | ||
clap = {version = "4.5", features = ["derive"]} | ||
clap = { version = "4.5", features = ["derive"] } | ||
clap_complete = "4.5" | ||
hex = "0.4" | ||
tiny-keccak = { version = "2.0", features = ["keccak"] } | ||
serde_json = "1.0" | ||
serde = "1.0" | ||
serde_derive = { version = "1.0" } | ||
inkwell = { version = "0.4.0", features = ["target-webassembly", "no-libffi-linking", "llvm16-0"], optional = true } | ||
inkwell = { version = "0.4.0", features = [ | ||
"target-webassembly", | ||
"no-libffi-linking", | ||
"llvm16-0", | ||
], optional = true } | ||
blake2-rfc = "0.2.18" | ||
handlebars = "5.1" | ||
contract-metadata = "4.0.2" | ||
semver = { version = "1.0", features = ["serde"] } | ||
tempfile = "3.10" | ||
libc = { version = "0.2", optional = true } | ||
tower-lsp = { version = "0.20", optional = true } | ||
tokio = { version = "1.27", features = ["rt", "io-std", "macros"], optional = true } | ||
tokio = { version = "1.27", features = [ | ||
"rt", | ||
"io-std", | ||
"macros", | ||
], optional = true } | ||
base58 = "0.2.0" | ||
sha2 = "0.10" | ||
ripemd = "0.1" | ||
|
@@ -71,7 +93,10 @@ forge-fmt = { path = "fmt", optional = true } | |
# We don't use ethers-core directly, but need the correct version for the | ||
# build to work. | ||
ethers-core = { version = "2.0.10", optional = true } | ||
soroban-sdk = { version = "22.0.0-rc.3.2", features = ["testutils"], optional = true } | ||
soroban-sdk = { version = "22.0.0-rc.3.2", features = [ | ||
"testutils", | ||
], optional = true } | ||
|
||
|
||
[dev-dependencies] | ||
num-derive = "0.4" | ||
|
@@ -91,7 +116,7 @@ rayon = "1" | |
walkdir = "2.4" | ||
ink_primitives = "5.0.0" | ||
wasm_host_attr = { path = "tests/wasm_host_attr" } | ||
num-bigint = { version = "0.4", features = ["rand", "serde"]} | ||
num-bigint = { version = "0.4", features = ["rand", "serde"] } | ||
|
||
[package.metadata.docs.rs] | ||
no-default-features = true | ||
|
@@ -104,7 +129,13 @@ soroban = ["soroban-sdk"] | |
default = ["llvm", "wasm_opt", "language_server", "soroban"] | ||
llvm = ["inkwell", "libc"] | ||
wasm_opt = ["llvm", "wasm-opt", "contract-build"] | ||
language_server = ["tower-lsp", "forge-fmt", "ethers-core", "tokio", "rust-lapper"] | ||
language_server = [ | ||
"tower-lsp", | ||
"forge-fmt", | ||
"ethers-core", | ||
"tokio", | ||
"rust-lapper", | ||
] | ||
|
||
[workspace] | ||
members = ["solang-parser", "fmt", "tests/wasm_host_attr"] |
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 |
---|---|---|
@@ -0,0 +1 @@ | ||
[{"name":"count","type":"function","inputs":[],"outputs":[{"name":"count","type":"uint64","internalType":"uint64"}],"stateMutability":"view"},{"name":"increment","type":"function","inputs":[],"outputs":[{"name":"","type":"uint64","internalType":"uint64"}],"stateMutability":"nonpayable"},{"name":"decrement","type":"function","inputs":[],"outputs":[{"name":"","type":"uint64","internalType":"uint64"}],"stateMutability":"nonpayable"},{"name":"additionu32","type":"function","inputs":[{"name":"a","type":"uint32","internalType":"uint32"},{"name":"b","type":"uint32","internalType":"uint32"}],"outputs":[{"name":"","type":"uint32","internalType":"uint32"}],"stateMutability":"nonpayable"}] |
Binary file not shown.
Binary file not shown.
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 |
---|---|---|
@@ -0,0 +1 @@ | ||
[{"name":"decrement","type":"function","inputs":[],"outputs":[{"name":"","type":"uint64","internalType":"uint64"}],"stateMutability":"nonpayable"}] |
Binary file not shown.
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 |
---|---|---|
@@ -0,0 +1 @@ | ||
[{"name":"count","type":"function","inputs":[],"outputs":[{"name":"count","type":"uint64","internalType":"uint64"}],"stateMutability":"view"},{"name":"increment","type":"function","inputs":[],"outputs":[{"name":"","type":"uint64","internalType":"uint64"}],"stateMutability":"nonpayable"},{"name":"decrement","type":"function","inputs":[],"outputs":[{"name":"","type":"uint64","internalType":"uint64"}],"stateMutability":"nonpayable"},{"name":"additionu32","type":"function","inputs":[{"name":"a","type":"uint32","internalType":"uint32"},{"name":"b","type":"uint32","internalType":"uint32"}],"outputs":[{"name":"","type":"uint32","internalType":"uint32"}],"stateMutability":"nonpayable"}] |
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
Binary file not shown.
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 |
---|---|---|
@@ -1,23 +1,23 @@ | ||
{ | ||
"type": "module", | ||
"dependencies": { | ||
"@stellar/stellar-sdk": "^12.0.1", | ||
"chai": "^5.1.1", | ||
"dotenv": "^16.4.5", | ||
"mocha": "^10.4.0" | ||
}, | ||
"scripts": { | ||
"build": "solang compile *.sol --target soroban && solang compile storage_types.sol --target soroban --release", | ||
"setup": "node setup.js", | ||
"test": "mocha *.spec.js --timeout 100000" | ||
}, | ||
"devDependencies": { | ||
"@eslint/js": "^9.4.0", | ||
"@types/mocha": "^10.0.6", | ||
"eslint": "^9.4.0", | ||
"expect": "^29.7.0", | ||
"globals": "^15.4.0", | ||
"typescript": "^5.4.5" | ||
} | ||
"type": "module", | ||
"dependencies": { | ||
"@stellar/stellar-sdk": "^12.0.1", | ||
"chai": "^5.1.1", | ||
"dotenv": "^16.4.7", | ||
"mocha": "^10.4.0" | ||
}, | ||
"scripts": { | ||
"build": "solang compile *.sol --target soroban && solang compile counter.sol --target soroban --release", | ||
"setup": "node setup.js", | ||
"test": "mocha *.spec.js --timeout 100000", | ||
"testcounter": "mocha counter.spec.js --timeout 100000" | ||
}, | ||
"devDependencies": { | ||
"@eslint/js": "^9.4.0", | ||
"@types/mocha": "^10.0.6", | ||
"eslint": "^9.4.0", | ||
"expect": "^29.7.0", | ||
"globals": "^15.4.0", | ||
"typescript": "^5.4.5" | ||
} | ||
} |
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 |
---|---|---|
@@ -0,0 +1 @@ | ||
[{"name":"sesa","type":"function","inputs":[],"outputs":[{"name":"sesa","type":"uint64","internalType":"uint64"}],"stateMutability":"view"},{"name":"sesa1","type":"function","inputs":[],"outputs":[{"name":"sesa1","type":"uint64","internalType":"uint64"}],"stateMutability":"view"},{"name":"sesa2","type":"function","inputs":[],"outputs":[{"name":"sesa2","type":"uint64","internalType":"uint64"}],"stateMutability":"view"},{"name":"sesa3","type":"function","inputs":[],"outputs":[{"name":"sesa3","type":"uint64","internalType":"uint64"}],"stateMutability":"view"},{"name":"inc","type":"function","inputs":[],"outputs":[],"stateMutability":"nonpayable"},{"name":"dec","type":"function","inputs":[],"outputs":[],"stateMutability":"nonpayable"}] |
Binary file not shown.
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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Oops, something went wrong.