diff --git a/mobile_verifier/src/reward_shares.rs b/mobile_verifier/src/reward_shares.rs index 3a8623c38..a9ca434d9 100644 --- a/mobile_verifier/src/reward_shares.rs +++ b/mobile_verifier/src/reward_shares.rs @@ -959,6 +959,8 @@ mod test { // todo: rebalance the tests to use a normalised hnt price let hnt_price = HntPrice::new(10000000000000000, 8); + assert_eq!(hnt_price.hnt_price, dec!(100000000)); + assert_eq!(hnt_price.price_per_hnt_bone, dec!(1)); let data_transfer_rewards = TransferRewards::from_transfer_sessions(hnt_price, data_transfer_map, &reward_shares) @@ -1010,6 +1012,8 @@ mod test { // todo: rebalance the tests to use a normalised hnt price let hnt_price = HntPrice::new(10000000000000000, 8); + assert_eq!(hnt_price.hnt_price, dec!(100000000)); + assert_eq!(hnt_price.price_per_hnt_bone, dec!(1)); let reward_shares = DataTransferAndPocAllocatedRewardBuckets::new(rewards_info.epoch_emissions); diff --git a/mobile_verifier/tests/integrations/hex_boosting.rs b/mobile_verifier/tests/integrations/hex_boosting.rs index 9d04c45f3..133c5375d 100644 --- a/mobile_verifier/tests/integrations/hex_boosting.rs +++ b/mobile_verifier/tests/integrations/hex_boosting.rs @@ -140,7 +140,10 @@ async fn test_poc_with_boosted_hexes(pool: PgPool) -> anyhow::Result<()> { .to_u64() .unwrap(); - let hnt_price = HntPrice::new(1000000000000000, 8); + // todo: rebalance the tests to use a normalised hnt price + let hnt_price = HntPrice::new(10000000000000000, 8); + assert_eq!(hnt_price.hnt_price, dec!(100000000)); + assert_eq!(hnt_price.price_per_hnt_bone, dec!(1)); let (_, rewards) = tokio::join!( // run rewards for poc and dc @@ -328,7 +331,10 @@ async fn test_poc_boosted_hexes_thresholds_not_met(pool: PgPool) -> anyhow::Resu let reward_info = default_rewards_info(82_191_780_821_917, Duration::hours(24)); - let hnt_price = HntPrice::new(1000000000000000, 8); + // todo: rebalance the tests to use a normalised hnt price + let hnt_price = HntPrice::new(10000000000000000, 8); + assert_eq!(hnt_price.hnt_price, dec!(100000000)); + assert_eq!(hnt_price.price_per_hnt_bone, dec!(1)); let (_, rewards) = tokio::join!( // run rewards for poc and dc @@ -492,7 +498,10 @@ async fn test_poc_with_multi_coverage_boosted_hexes(pool: PgPool) -> anyhow::Res let hex_boosting_client = MockHexBoostingClient::new(boosted_hexes); - let hnt_price = HntPrice::new(1000000000000000, 8); + // todo: rebalance the tests to use a normalised hnt price + let hnt_price = HntPrice::new(10000000000000000, 8); + assert_eq!(hnt_price.hnt_price, dec!(100000000)); + assert_eq!(hnt_price.price_per_hnt_bone, dec!(1)); let (_, rewards) = tokio::join!( // run rewards for poc and dc @@ -668,7 +677,10 @@ async fn test_expired_boosted_hex(pool: PgPool) -> anyhow::Result<()> { let hex_boosting_client = MockHexBoostingClient::new(boosted_hexes); - let hnt_price = HntPrice::new(1000000000000000, 8); + // todo: rebalance the tests to use a normalised hnt price + let hnt_price = HntPrice::new(10000000000000000, 8); + assert_eq!(hnt_price.hnt_price, dec!(100000000)); + assert_eq!(hnt_price.price_per_hnt_bone, dec!(1)); let (_, rewards) = tokio::join!( // run rewards for poc and dc @@ -801,7 +813,10 @@ async fn test_reduced_location_score_with_boosted_hexes(pool: PgPool) -> anyhow: .to_u64() .unwrap(); - let hnt_price = HntPrice::new(1000000000000000, 8); + // todo: rebalance the tests to use a normalised hnt price + let hnt_price = HntPrice::new(10000000000000000, 8); + assert_eq!(hnt_price.hnt_price, dec!(100000000)); + assert_eq!(hnt_price.price_per_hnt_bone, dec!(1)); let (_, rewards) = tokio::join!( // run rewards for poc and dc @@ -982,7 +997,10 @@ async fn test_distance_from_asserted_removes_boosting_but_not_location_trust( .to_u64() .unwrap(); - let hnt_price = HntPrice::new(1000000000000000, 8); + // todo: rebalance the tests to use a normalised hnt price + let hnt_price = HntPrice::new(10000000000000000, 8); + assert_eq!(hnt_price.hnt_price, dec!(100000000)); + assert_eq!(hnt_price.price_per_hnt_bone, dec!(1)); let (_, rewards) = tokio::join!( // run rewards for poc and dc @@ -1188,7 +1206,10 @@ async fn test_poc_with_cbrs_and_multi_coverage_boosted_hexes(pool: PgPool) -> an .to_u64() .unwrap(); - let hnt_price = HntPrice::new(1000000000000000, 8); + // todo: rebalance the tests to use a normalised hnt price + let hnt_price = HntPrice::new(10000000000000000, 8); + assert_eq!(hnt_price.hnt_price, dec!(100000000)); + assert_eq!(hnt_price.price_per_hnt_bone, dec!(1)); let (_, rewards) = tokio::join!( // run rewards for poc and dc diff --git a/mobile_verifier/tests/integrations/rewarder_poc_dc.rs b/mobile_verifier/tests/integrations/rewarder_poc_dc.rs index 8419d3b25..032944a39 100644 --- a/mobile_verifier/tests/integrations/rewarder_poc_dc.rs +++ b/mobile_verifier/tests/integrations/rewarder_poc_dc.rs @@ -47,7 +47,10 @@ async fn test_poc_and_dc_rewards(pool: PgPool) -> anyhow::Result<()> { let hex_boosting_client = MockHexBoostingClient::new(boosted_hexes); + // todo: rebalance the tests to use a normalised hnt price let hnt_price = HntPrice::new(10000000000000000, 8); + assert_eq!(hnt_price.hnt_price, dec!(100000000)); + assert_eq!(hnt_price.price_per_hnt_bone, dec!(1)); let (_, rewards) = tokio::join!( // run rewards for poc and dc