Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Luxor QA Plan #5119

Open
13 of 26 tasks
freakstatic opened this issue Mar 28, 2024 · 6 comments
Open
13 of 26 tasks

Luxor QA Plan #5119

freakstatic opened this issue Mar 28, 2024 · 6 comments

Comments

@freakstatic
Copy link
Contributor

freakstatic commented Mar 28, 2024

Features Tests

Proposal for reducing council budget

  • Create a proposal to reduce the council budget, check the budget value before and after the proposal execution
  • Try to reduce the council budget more than the current value on the council budget
  • Try to make a proposal with a negative reduction

Vested spending from WG budgets

  • Create a vested spending from the WG budget and verify that the destination wallet receives the right amount of vested tokens
  • Try to create a vested spending with a value higher than the amount in the WG budget
  • Check what happens if an account has too many vesting schedules already and we do the payment

Proposal for adjusting validator rewards budget

  • Create a proposal with a validator reward multiplier (Ex: 0.5) and verify that the validator and nominators rewards match the expected new value
  • Try to create proposals with values outside of the range (lower than 0.2 and higher than 1.0)

Proposal for adjusting CRT pallet constraints

  • Create a proposal to update all the constraints and verify the chain state after the proposal execution
  • Create a proposal to update each constraint individually and check if only the selected constraint was changed and the rest didn't reset to a default value
    • max_yearly_rate
    • min_amm_slope
    • min_sale_duration
    • min_revenue_split_duration
    • min_revenue_split_time_to_start
    • sale_platform_fee
    • amm_buy_tx_fees
    • amm_sell_tx_fees
    • bloat_bond

Add proxy pallet

  • Assign a proxy account to the account A and try to perform a operation that only the account A can perform using the proxy account
  • Remove the proxy account association and try to perform a transaction that only the account A can perform using the proxy account
    WIP

Pre-Upgrade Tests

  • Try to connect and sync the joystream-node and QN (compiled from the luxor branch) to a nara chain

Post-Upgrade Tests

  • Try to connect nara pioneer (RPC and QN) to a luxor chain
  • Try to connect nara atlas (RPC, QN and Orion) to a luxor chain
  • Try to sync the luxor joystream-node and QN with the mainnet chain
  • Verify that the validator rewards match the expect value considering the validator reward multiplier default value
@ignazio-bovo
Copy link
Contributor

ignazio-bovo commented Apr 2, 2024

Enhancements

Post Uprade test

  • council.eraPayoutDampingFactor should be 100%

Vesting WG spending

  • Test our rivalrous locks logic
    pub static ref NON_RIVALROUS_LOCKS: Vec<LockIdentifier> = [
        VotingLockId::get(),
        VESTING_LOCK_ID,
        InvitedMemberLockId::get(),
        BoundStakingAccountLockId::get(),
    ]
    .to_vec();
  • Vesting schedule setup with the following parameters:
    • amount > 0 & amount_per_block == 0 should fail
    • amount == 0 & amount_per_block > 0 should fail
    • amount > 0 & amount_per_block == 0 should succeed and have similar semantics to a spend_budget result
    • amount > 0 & amount_per_block > amount should fail

Correction

  • Try to create proposals with values outside of the range (lower than 0.2 and higher than 2.0): The correct range for the damping factor should be [0,1] @kdembler please confirm

@freakstatic
Copy link
Contributor Author

  • Try to create proposals with values outside of the range (lower than 0.2 and higher than 2.0): The correct range for the damping factor should be [0,1] @kdembler please confirm

yeah that info was outdated, I have corrected it ✅
thanks for you input 👍

@kdembler
Copy link
Member

kdembler commented Apr 9, 2024

Reduce council budget

Happy case proposal: https://168.119.228.195.nip.io/pioneer/#/proposals/preview/1
Budget before reduction: 366,666.67
Budget after reduction: 66,666.67 ✅

Too much reduction proposal (created via polkadot.js, pioneer properly validated): https://168.119.228.195.nip.io/pioneer/#/proposals/preview/2
Budget before reduction: 66,666.67
Execution failed ✅

Try to make a proposal with a negative reduction is not possible. The proposal argument is u128 so it's not possible to pass a negative value ✅

Vested spending

Happy case: https://polkadot.js.org/apps/?rpc=wss%3A%2F%2F168.119.228.195.nip.io%2Fws-rpc#/explorer/query/0x945903fb2c797ad6b5ee1e1f872407f347b7a89550cbe0d465a4b1db4d80e689
Worked fine✅

Bigger spend than WG budget: https://polkadot.js.org/apps/?rpc=wss%3A%2F%2F168.119.228.195.nip.io%2Fws-rpc#/explorer/query/0xfadad2e8cc29876c14ae630723f3e611eeb689c06086e93096cfd9a474c8e4ef
Failed with storageWorkingGroup.InsufficientBudgetForSpending

Exceeding vesting schedules limit: https://polkadot.js.org/apps/?rpc=wss%3A%2F%2F168.119.228.195.nip.io%2Fws-rpc#/explorer/query/0x56d17c7715defee8c84951eaa52c56a694357729134cdb0316847cfa7aabdc5f
Failed with vesting.AtMaxVestingSchedules

Edge case params (per @ignazio-bovo):

  • amount > 0 & amount_per_block == 0 fails as expected

  • amount == 0 & amount_per_block > 0 fails as expected

  • amount > 0 & amount_per_block == 0 was suggested to succeed but it fails with invalid vesting params, I think that's the correct behaviour

  • amount > 0 & amount_per_block == amount works (vesting is done in 1 block)
    CleanShot 2024-04-09 at 14 00 51@2x

  • amount > 0 & amount_per_block > amount was suggested to fail but it works and the vesting is done immediately
    CleanShot 2024-04-09 at 14 01 10@2x

LGTM ✅

@kdembler
Copy link
Member

kdembler commented Apr 9, 2024

CRT constrains update

Update all params: https://168.119.228.195.nip.io/pioneer/#/proposals/preview/6
Inputs:
CleanShot 2024-04-09 at 14 13 55@2x
Before:
CleanShot 2024-04-09 at 14 14 24@2x
After:
CleanShot 2024-04-09 at 14 17 53@2x

All good ✅

Update single param: https://168.119.228.195.nip.io/pioneer/#/proposals/preview/7
After:
CleanShot 2024-04-09 at 14 26 00@2x

All good ✅

@kdembler
Copy link
Member

kdembler commented Apr 9, 2024

@kdembler
Copy link
Member

kdembler commented Apr 9, 2024

Proxy pallet

Created Any proxy: https://polkadot.js.org/apps/?rpc=wss%3A%2F%2F168.119.228.195.nip.io%2Fws-rpc#/explorer/query/0x2c3dc3ca3a27620b7e0e34cb2927d708b7f6d1f9d2149da37e834f2a204e6043

Sent funds via a proxy: https://polkadot.js.org/apps/?rpc=wss%3A%2F%2F168.119.228.195.nip.io%2Fws-rpc#/explorer/query/0xf7656e31621c2c017c88f14b2ac5a478b114baf27a0cc3b244ba5e0529c976ca

Properly executed, funds were withdrawn from the proxied account ✅
Call fails after proxy was removed ✅

Created Referendum proxy, balance transfer failed ✅, referendum calls succeeded ✅

@kdembler kdembler changed the title WIP: Luxor QA Plan Luxor QA Plan Apr 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants