omgnetwork / elixir-omg

OMG-Network repository of Watcher and Watcher Info
https://omg.network
Apache License 2.0
211 stars 59 forks source link

Watcher_Info itest client `get_balance` varrying response #1293

Open pnowosie opened 4 years ago

pnowosie commented 4 years ago

Experienced in Cabbage tests (fee_claiming) Client get_balance response is either map or list(map).

Balance response for Alice: %{
  "amount" => 3000000000000000000,
  "currency" => "0x0000000000000000000000000000000000000000"
}

11:54:04.164 [info]         Then "Alice" should have "3" ETH on the child chain

11:54:04.188 [info]         When "Alice" sends "Bob" "2" ETH on the child chain
Balance response for Bob: %{
  "amount" => 2000000000000000000,
  "currency" => "0x0000000000000000000000000000000000000000"
}

11:54:12.229 [info]         Then "Bob" should have "2" ETH on the child chain
Balance response for FeeClaimer: [
  %{
    "amount" => 10000000000000000000,
    "currency" => "0x0000000000000000000000000000000000000000"
  }
]
InoMurko commented 4 years ago

hm... is the issue on the cabbage tests or watcher info response? it would be good to include how to reproduce this.

pnowosie commented 4 years ago

This is cabbage test client - Watcher responds with array tirelessly. To reproduce see the usage of Client.get_balance(...) in <elixir-omg>/priv/apps/itest/test/itest/fee_claiming_test.exs