Unverified Commit 5866e3ab authored by Tarik Gul's avatar Tarik Gul Committed by GitHub
Browse files

fix: staking payouts historicApi, and add tests (#762)



* staking payouts historicApi

* start tests

* boilerplate for tests

* mock data and types for tests

* stakingPayouts reponse

* mock data for staking payouts

* lint eraRewardPoints

* setup main test

* adjust custom response

* generate correct types for mock data

* correct nominator data

* correct eraRewardPoints

* add error tests

* fix eraRewardPoints types

* add test for extractTotalValidatorRewardPoints

* replace EraRewardPoints type

* lint

* clean empty line

* tests for eraExposure

* add deriveNominatorExposures for vals and noms

* general cleanup, and DRY

* add polkadot v9122 registry

* add docs and switch things over to polkadotV9122registry

* lint

* fix doc grumbles

* Update src/services/accounts/AccountsStakingPayoutsService.spec.ts

Co-authored-by: default avatarNiklas Adolfsson <[email protected]>

* cleanup comments

* mapToBe -> mockEraRewardsMap

* lint

* Update src/services/accounts/AccountsStakingPayoutsService.spec.ts

Co-authored-by: default avatarNiklas Adolfsson <[email protected]>
Co-authored-by: default avatarDavid <[email protected]>
parent 3eda2420
Pipeline #167502 passed with stages
in 3 minutes and 13 seconds
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment