@Test public void testMinersFairness() { ep.network().run(10_000); HashMap<ETHMiner, Double> rs = m0.head.allRewards(); double c0 = rs.getOrDefault(m0, 0.0); double c1 = rs.getOrDefault(m1, 0.0); double diff = Math.abs(c0 - c1); double th = (c0 + c1) / 10; Assert.assertTrue(diff < th); }
@Override public BlockChainNetwork<POWBlock, ETHMiner> network() { return network; }
ETHPoW implements Protocol { @Override public BlockChainNetwork<POWBlock, ETHMiner> network() { return network; } }
ETHPoW implements Protocol { @Override public BlockChainNetwork<POWBlock, ETHMiner> network() { return network; } ETHPoW(ETHPoWParameters params); }
ETHPoW implements Protocol { @Override public BlockChainNetwork<POWBlock, ETHMiner> network() { return network; } ETHPoW(ETHPoWParameters params); @Override BlockChainNetwork<POWBlock, ETHMiner> network(); @Override Protocol copy(); ETHMiner getByzantineNode(); @Override void init(); }
ETHPoW implements Protocol { @Override public BlockChainNetwork<POWBlock, ETHMiner> network() { return network; } ETHPoW(ETHPoWParameters params); @Override BlockChainNetwork<POWBlock, ETHMiner> network(); @Override Protocol copy(); ETHMiner getByzantineNode(); @Override void init();  }