Hard-code Y coordinate of UmbralParameter.U

pull/507/head
David Núñez 2018-12-06 10:57:46 +01:00 committed by szotov
parent de093e1236
commit 4ec3ea9abd
2 changed files with 2 additions and 0 deletions

View File

@ -14,6 +14,7 @@ contract MiningAdjudicator {
uint8 public constant UMBRAL_PARAMETER_U_SIGN = 0x02;
uint256 public constant UMBRAL_PARAMETER_U_XCOORD = 0x03c98795773ff1c241fc0b1cced85e80f8366581dda5c9452175ebd41385fa1f;
uint256 public constant UMBRAL_PARAMETER_U_YCOORD = 0x7880ed56962d7c0ae44d6f14bb53b5fe64b31ea44a41d0316f3a598778f0f936;
using UmbralDeserializer for bytes;

View File

@ -89,6 +89,7 @@ def test_evaluate_cfrag(testerchain, escrow, adjudicator_contract):
u_sign = 2 + (u_ycoord % 2)
assert u_sign == adjudicator_contract.functions.UMBRAL_PARAMETER_U_SIGN().call()
assert u_xcoord == adjudicator_contract.functions.UMBRAL_PARAMETER_U_XCOORD().call()
assert u_ycoord == adjudicator_contract.functions.UMBRAL_PARAMETER_U_YCOORD().call()
# TODO: Move this to an integration test
test_data = os.urandom(40)