Skip to content

Commit 77a3fd4

Browse files
committed
fix: test description
1 parent 303821a commit 77a3fd4

File tree

2 files changed

+14
-18
lines changed

2 files changed

+14
-18
lines changed

packages/client/src/actions/merits.test.ts

Lines changed: 12 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -4,25 +4,21 @@ import { chainId } from '@aave/types';
44
import { describe, expect, it } from 'vitest';
55
import { meritClaimRewards } from './incentives';
66

7-
describe('Given the Aave client', () => {
8-
describe('And a user with no merits', () => {
9-
const wallet = createNewWallet();
7+
describe('Given a chain supporting Merit rewards', () => {
8+
const wallet = createNewWallet();
109

11-
describe('When the user wants to claim merits', () => {
12-
it('Then it should not return any merits to claim', async () => {
13-
const result = await meritClaimRewards(client, {
14-
user: evmAddress(wallet.account!.address),
15-
chainId: chainId(1),
16-
});
17-
assertOk(result);
18-
expect(result.value).toBeNull();
10+
describe('When a user does not have any Merit rewards', () => {
11+
it('Then they should not see any Merit rewards to claim', async () => {
12+
const result = await meritClaimRewards(client, {
13+
user: evmAddress(wallet.account!.address),
14+
chainId: chainId(1),
1915
});
16+
assertOk(result);
17+
expect(result.value).toBeNull();
2018
});
19+
});
2120

22-
describe('And a user with merits', () => {
23-
describe('When the user wants to claim merits', () => {
24-
it.todo('Then it should return the merits claimed');
25-
});
26-
});
21+
describe('When a user have Merit rewards to claim', () => {
22+
it.todo('Then they should be able to claim them');
2723
});
2824
});

packages/react/src/incentives.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ import { useSuspendableQuery } from './helpers';
1414
export type UseMeritClaimRewardsArgs = MeritClaimRewardsRequest;
1515

1616
/**
17-
* Fetch Merit claim rewards transaction for a user.
17+
* Fetches Merit claim rewards for a user with the transaction request to claim them.
1818
*
1919
* This signature supports React Suspense:
2020
*
@@ -31,7 +31,7 @@ export function useMeritClaimRewards(
3131
): SuspenseResult<MeritClaimRewardsTransaction | null>;
3232

3333
/**
34-
* Fetch Merit claim rewards transaction for a user.
34+
* Fetches Merit claim rewards for a user with the transaction request to claim them.
3535
*
3636
* ```tsx
3737
* const { data, loading } = useMeritClaimRewards({

0 commit comments

Comments
 (0)