Skip to content

Commit 8214693

Browse files
committed
more test
1 parent 567b55a commit 8214693

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

70 files changed

+5492
-373
lines changed

.gitmodules

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,3 +34,6 @@
3434
[submodule "tests/evm-tools-compatibility/foundry/lib/forge-std"]
3535
path = tests/evm-tools-compatibility/foundry/lib/forge-std
3636
url = https://github.com/foundry-rs/forge-std
37+
[submodule "tests/integration_tests/contracts/openzeppelin-contracts-upgradeable"]
38+
path = tests/integration_tests/contracts/openzeppelin-contracts-upgradeable
39+
url = https://github.com/OpenZeppelin/openzeppelin-contracts-upgradeable.git

Makefile

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -239,6 +239,12 @@ lint-fix:
239239
lint-fix-contracts:
240240
solhint --fix contracts/**/*.sol
241241

242+
lint-py:
243+
flake8 --show-source --count --statistics \
244+
--format="::error file=%(path)s,line=%(row)d,col=%(col)d::%(path)s:%(row)d:%(col)d: %(code)s %(text)s" \
245+
--exclude=tests/integration_tests/contracts \
246+
tests/integration_tests/
247+
242248
.PHONY: lint lint-fix lint-contracts lint-go lint-python
243249

244250
format: format-go format-python format-shell

tests/integration_tests/.flake8

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
[flake8]
2+
max-line-length = 88
3+
extend-ignore = E203
4+
exclude = .git,__pycache__,./integration_tests/contracts
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
local config = import 'default.jsonnet';
2+
local chain = (import 'chains.jsonnet')[std.extVar('CHAIN_CONFIG')];
3+
4+
config {
5+
'evm-canary-net-1'+: {
6+
accounts: super.accounts[:std.length(super.accounts) - 1] + [
7+
{
8+
'coin-type': 60,
9+
name: 'user' + i,
10+
coins: '100000000000000000' + chain.evm_denom,
11+
}
12+
for i in std.range(0, 5)
13+
],
14+
},
15+
}

tests/integration_tests/configs/chains.jsonnet

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
feemarket: {
2828
params: {
2929
base_fee: '1000000000',
30-
min_gas_price: '0',
30+
min_gas_price: '1000000000',
3131
},
3232
},
3333
},

tests/integration_tests/configs/default.jsonnet

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
local chain = (import 'chains.jsonnet')[std.extVar('CHAIN_CONFIG')];
2+
local gas_price = 1000000000;
23

34
{
45
dotenv: '../../scripts/.env',
@@ -39,13 +40,13 @@ local chain = (import 'chains.jsonnet')[std.extVar('CHAIN_CONFIG')];
3940
'coin-type': 60,
4041
coins: '100000000000000000000' + chain.evm_denom,
4142
staked: '10000000000000000000' + chain.evm_denom,
42-
gas_prices: '0.01' + chain.evm_denom,
43+
gas_prices: gas_price + chain.evm_denom,
4344
mnemonic: '${VALIDATOR1_MNEMONIC}',
4445
}, {
4546
'coin-type': 60,
4647
coins: '100000000000000000000' + chain.evm_denom,
4748
staked: '10000000000000000000' + chain.evm_denom,
48-
gas_prices: '0.01' + chain.evm_denom,
49+
gas_prices: gas_price + chain.evm_denom,
4950
mnemonic: '${VALIDATOR2_MNEMONIC}',
5051
config: {
5152
db_backend: 'pebbledb',
@@ -57,7 +58,7 @@ local chain = (import 'chains.jsonnet')[std.extVar('CHAIN_CONFIG')];
5758
'coin-type': 60,
5859
coins: '100000000000000000000' + chain.evm_denom,
5960
staked: '10000000000000000000' + chain.evm_denom,
60-
gas_prices: '0.01' + chain.evm_denom,
61+
gas_prices: gas_price + chain.evm_denom,
6162
mnemonic: '${VALIDATOR3_MNEMONIC}',
6263
config: {
6364
db_backend: 'goleveldb',
@@ -106,6 +107,8 @@ local chain = (import 'chains.jsonnet')[std.extVar('CHAIN_CONFIG')];
106107
evm_denom: chain.evm_denom,
107108
active_static_precompiles: [
108109
'0x0000000000000000000000000000000000000800',
110+
'0x0000000000000000000000000000000000000801',
111+
'0x0000000000000000000000000000000000000805',
109112
'0x0000000000000000000000000000000000000807',
110113
],
111114
},
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
local config = import 'default.jsonnet';
2+
3+
config {
4+
'evm-canary-net-1'+: {
5+
'app-config'+: {
6+
'json-rpc'+: {
7+
'batch-request-limit': 2,
8+
'batch-response-max-size': 7188483, // memory_byte_size - 1
9+
},
10+
},
11+
},
12+
}
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
local config = import 'default.jsonnet';
2+
3+
config {
4+
'evm-canary-net-1'+: {
5+
genesis+: {
6+
app_state+: {
7+
feemarket+: {
8+
params+: {
9+
elasticity_multiplier: 3,
10+
base_fee_change_denominator: 100000000,
11+
// min_gas_price: '0.000000000000000000', # TODO: remove after basefee fix
12+
},
13+
},
14+
},
15+
},
16+
},
17+
}
Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
local config = import 'default.jsonnet';
2+
local rly_chain = import 'rly_chain.jsonnet';
3+
local rly_common = import 'rly_common.jsonnet';
4+
local chain = (import 'chains.jsonnet')[std.extVar('CHAIN_CONFIG')];
5+
local basic = config['evm-canary-net-1'];
6+
local ibc_common = import 'ibc_common.jsonnet';
7+
8+
config {
9+
'evm-canary-net-1'+: ibc_common {
10+
key_name: 'signer2',
11+
'account-prefix': chain['account-prefix'],
12+
},
13+
'evm-canary-net-2'+: basic + ibc_common {
14+
key_name: 'signer1',
15+
'account-prefix': chain['account-prefix'],
16+
validators: [validator {
17+
base_port: 26800 + i * 10,
18+
} for i in std.range(0, std.length(super.validators) - 1) for validator in [super.validators[i]]],
19+
},
20+
relayer: rly_common {
21+
chains: [
22+
rly_chain {
23+
id: 'evm-canary-net-1',
24+
gas_price+: {
25+
denom: chain.evm_denom,
26+
},
27+
},
28+
rly_chain {
29+
id: 'evm-canary-net-2',
30+
gas_price+: {
31+
denom: chain.evm_denom,
32+
},
33+
},
34+
],
35+
},
36+
}
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
{
2+
'coin-type': 60,
3+
'app-config'+: {
4+
'index-events': super['index-events'] + ['message.action'],
5+
},
6+
genesis+: {
7+
app_state+: {
8+
feemarket+: {
9+
params+: {
10+
no_base_fee: true,
11+
base_fee: '0',
12+
min_gas_price: '0',
13+
},
14+
},
15+
staking+: {
16+
params+: {
17+
unbonding_time: '1814400s',
18+
},
19+
},
20+
},
21+
},
22+
}

0 commit comments

Comments
 (0)