Go to file
2022-04-21 09:44:24 +05:30
proto Message for creating bond 2022-04-21 09:44:24 +05:30
scripts Message for creating bond 2022-04-21 09:44:24 +05:30
src Fix create bond message 2022-04-21 09:44:24 +05:30
.gitignore Add failing test case for sending tokens 2022-04-21 09:44:24 +05:30
jest.config.js Add failing test case for sending tokens 2022-04-21 09:44:24 +05:30
package.json Message for creating bond 2022-04-21 09:44:24 +05:30
README.md Fix create bond message 2022-04-21 09:44:24 +05:30
tsconfig.json Add failing test case for sending tokens 2022-04-21 09:44:24 +05:30
yarn.lock Message for creating bond 2022-04-21 09:44:24 +05:30

chiba-clonk-client

Development

Follow these steps to run the tests:

  • After cloning this repo run:

    yarn
    
  • Clone the chiba-clonk repo and change directory to repo directory.

  • Run the chain using ./init.sh.

  • Add a second account with the following:

    ethermintd keys add <KEY_NAME> --keyring-backend test
    
    # Example
    ethermintd keys add key2 --keyring-backend test
    
  • Get the account details using:

    ethermintd keys list
    
  • Use the address of key mykey as the sender address. Copy the address and assign it to SENDER_ADDRESS in the test file.

  • Copy the address of other account and assign it to variable TO_ADDRESS in test file.

  • To export the sender private key run:

    ethermintd keys export mykey --unarmored-hex --unsafe
    
  • Copy the private key and assign it to variable SENDER_PRIVATE_KEY in the test file.

  • Perform the following steps for testing gov module:

    • Submit a proposal

      ethermintd tx gov submit-proposal --title="Test Proposal" --description="My awesome proposal" --type="Text" --deposit="10000000aphoton" --from mykey --fees 20aphoton
      
    • Query for proposal

      ethermintd query gov proposals
      
  • Run the test in chiba-clonk-client repo:

    yarn test
    
  • Check account balances after running test:

    ethermintd query bank balances <ADDRESS>
    
    # Example
    ethermintd query bank balances ethm1ayxjyxxa3z9z0rjff7rpr67h8aqfgn2t9009zc
    
  • Check votes for proposal id 1

    # Query votes
    ethermintd query gov votes 1
    
    # Check votes tally
    ethermintd query gov tally 1
    
  • Check bonds list:

    ethermintd query bond list