Skip to content

Commit a0afef1

Browse files
committed
Update README
1 parent 398987c commit a0afef1

15 files changed

+15
-27
lines changed

tokens/token-swap/README.md

+2-13
Original file line numberDiff line numberDiff line change
@@ -317,16 +317,5 @@ https://github.com/solana-developers/program-examples/blob/419cb6b6c20e8b1c65711
317317
This code burns the specified amount of liquidity tokens (amount) by calling the token::burn function. The liquidity tokens are destroyed, reducing the total supply.
318318
Finally, this code returns Ok(()) if all operations in the function executed successfully. This indicates that the liquidity withdrawal was completed without any errors.
319319

320-
321-
322-
323-
324-
325-
326-
327-
328-
329-
330-
331-
332-
320+
## Potential extensions
321+
- Add instruction for the admin to change fee

tokens/token-swap/native/tests/create_amm.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -53,4 +53,4 @@ describe('Create AMM', async () => {
5353

5454
await expectRevert(client.processTransaction(tx));
5555
});
56-
});
56+
});

tokens/token-swap/native/tests/create_pool.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -82,4 +82,4 @@ describe('Create Pool', async () => {
8282
const txPromise = client.processTransaction(tx);
8383
await expectRevert(txPromise);
8484
})
85-
});
85+
});

tokens/token-swap/native/tests/deposit_liquidity.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -216,4 +216,4 @@ describe('Deposit liquidity', async () => {
216216
expect(poolABalance2).to.equal(poolABalance + amount_a2);
217217
expect(poolBBalance2).to.equal(poolBBalance + 60.75 * 10 ** 6);
218218
})
219-
});
219+
});

tokens/token-swap/native/tests/swap_exact_tokens_for_tokens.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -137,4 +137,4 @@ describe('Swap', async () => {
137137
expect(poolABalance).to.equal(amount_a + input);
138138
expect(poolBBalance).to.be.lessThan(amount_b);
139139
})
140-
});
140+
});
+1-1
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
export * from './instructions';
2-
export * from './state';
2+
export * from './state';

tokens/token-swap/native/tests/ts/instructions/create_amm.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -54,4 +54,4 @@ export function createCreateAmmInstruction(amm: PublicKey, admin: PublicKey, pay
5454
});
5555

5656
return ix;
57-
}
57+
}

tokens/token-swap/native/tests/ts/instructions/create_pool.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -60,4 +60,4 @@ export function createCreatePoolInstruction(amm: PublicKey, pool: PublicKey, poo
6060
});
6161

6262
return ix;
63-
}
63+
}

tokens/token-swap/native/tests/ts/instructions/deposit_liquidity.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -60,4 +60,4 @@ export function createDepositLiquidityInstruction(pool, poolAuthority, depositor
6060
})
6161

6262
return ix;
63-
}
63+
}

tokens/token-swap/native/tests/ts/instructions/index.ts

-1
Original file line numberDiff line numberDiff line change
@@ -11,4 +11,3 @@ export enum AmmInstruction {
1111
SwapExactTokensForTokens = 3,
1212
WithdrawLiquidity = 4,
1313
}
14-

tokens/token-swap/native/tests/ts/instructions/withdraw_liquidity.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -56,4 +56,4 @@ export function createWithdrawLiquidityInstruction(pool, poolAuthority, deposito
5656
})
5757

5858
return ix;
59-
}
59+
}

tokens/token-swap/native/tests/ts/state/amm.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -28,4 +28,4 @@ export const AmmSchema = new Map([
2828
['fee', 'u16'],
2929
]
3030
}]
31-
]);
31+
]);
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
export * from "./amm";
2-
export * from "./pool";
2+
export * from "./pool";

tokens/token-swap/native/tests/ts/state/pool.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -34,4 +34,4 @@ export const PoolSchema = new Map([
3434
['mint_b', ['u8', 32]],
3535
]
3636
}]
37-
]);
37+
]);

tokens/token-swap/native/tests/utils.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -25,4 +25,4 @@ export const expectRevert = async (promise: Promise<any>) => {
2525
// Otherwise swallow the error as expected
2626
return;
2727
}
28-
};
28+
};

0 commit comments

Comments
 (0)