Skip to content

Commit

Permalink
chore(apps/playground-api, ci): Extend pg future swap block_period (#…
Browse files Browse the repository at this point in the history
…1454)

* extend block period to 20

* add pg-api on ci

* minor fix
  • Loading branch information
canonbrother authored May 20, 2022
1 parent baea372 commit 146e111
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ jobs:
strategy:
matrix:
platform: [ linux/amd64 ]
app: [ legacy-api, ocean-api, status-api ]
app: [ legacy-api, ocean-api, playground-api, status-api ]
steps:
- name: Set up QEMU
uses: docker/setup-qemu-action@8b122486cedac8393e77aa9734c3528886e4a1a8
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ it('should have gov set', async () => {
'v0/token/16/loan_payback_fee_pct/14': '0.01',
'v0/params/dfip2203/active': 'true',
'v0/params/dfip2203/reward_pct': '0.05',
'v0/params/dfip2203/block_period': '10'
'v0/params/dfip2203/block_period': '20'
})
})

Expand Down Expand Up @@ -221,12 +221,12 @@ it('should have gov set', async () => {

const attributes = await testing.rpc.masternode.getGov('ATTRIBUTES')
expect(attributes.ATTRIBUTES['v0/params/dfip2203/active']).toStrictEqual('true')
expect(attributes.ATTRIBUTES['v0/params/dfip2203/block_period']).toStrictEqual('10')
expect(attributes.ATTRIBUTES['v0/params/dfip2203/block_period']).toStrictEqual('20')
expect(attributes.ATTRIBUTES['v0/params/dfip2203/reward_pct']).toStrictEqual('0.05')

const current = await testing.container.getBlockCount()
const next = await testing.container.call('getfutureswapblock')
expect(next - current).toBeLessThanOrEqual(10)
expect(next - current).toBeLessThanOrEqual(20)
await testing.generate(next - current)

{
Expand Down
2 changes: 1 addition & 1 deletion apps/playground-api/src/setups/setup.gov.ts
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ export class SetupGov extends PlaygroundSetup<Record<string, any>> {
await this.client.masternode.setGov({
ATTRIBUTES: {
'v0/params/dfip2203/reward_pct': '0.05',
'v0/params/dfip2203/block_period': '10'
'v0/params/dfip2203/block_period': '20'
}
})
await this.generate(1)
Expand Down

0 comments on commit 146e111

Please sign in to comment.