Skip to content
This repository has been archived by the owner on Apr 4, 2024. It is now read-only.

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
  • Loading branch information
yihuang committed Aug 30, 2022
1 parent 89a2caf commit 15ccfc4
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 13 deletions.
4 changes: 2 additions & 2 deletions tests/integration_tests/configs/broken-ethermintd.nix
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{ pkgs ? import ../../nix { } }:
let ethermintd = (pkgs.callPackage ../../. { });
{ pkgs ? import ../../../nix { } }:
let ethermintd = (pkgs.callPackage ../../../. { });
in
ethermintd.overrideAttrs (oldAttrs: {
patches = oldAttrs.patches or [ ] ++ [
Expand Down
11 changes: 1 addition & 10 deletions tests/integration_tests/configs/rollback-test.jsonnet
Original file line number Diff line number Diff line change
@@ -1,18 +1,9 @@
local config = import 'default.jsonnet';

config {
'cronos_777-1'+: {
'ethermint_9000-1'+: {
validators: super.validators + [{
name: 'fullnode',
}],
genesis+: {
app_state+: {
feemarket: {
params: {
no_base_fee: true,
},
},
},
},
},
}
3 changes: 3 additions & 0 deletions tests/integration_tests/cosmoscli.py
Original file line number Diff line number Diff line change
Expand Up @@ -826,3 +826,6 @@ def query_base_fee(self, **kwargs):
)
)["base_fee"]
)

def rollback(self):
self.raw("rollback", home=self.data_dir)
2 changes: 1 addition & 1 deletion tests/integration_tests/test_rollback.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ def custom_ethermint(tmp_path_factory):
yield from setup_custom_ethermint(
path,
26300,
Path(__file__).parent / "configs/rollback-test-network.jsonnet",
Path(__file__).parent / "configs/rollback-test.jsonnet",
post_init=post_init(broken_binary),
wait_port=False,
)
Expand Down
8 changes: 8 additions & 0 deletions tests/integration_tests/utils.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import json
import os
import socket
import subprocess
import sys
import time
from pathlib import Path
Expand Down Expand Up @@ -152,3 +153,10 @@ def send_successful_transaction(w3):
def eth_to_bech32(addr, prefix=ETHERMINT_ADDRESS_PREFIX):
bz = bech32.convertbits(HexBytes(addr), 8, 5)
return bech32.bech32_encode(prefix, bz)


def supervisorctl(inipath, *args):
subprocess.run(
(sys.executable, "-msupervisor.supervisorctl", "-c", inipath, *args),
check=True,
)

0 comments on commit 15ccfc4

Please sign in to comment.