diff --git a/.prettierrc b/.prettierrc deleted file mode 100644 index a1b4b5e..0000000 --- a/.prettierrc +++ /dev/null @@ -1,7 +0,0 @@ -{ - "printWidth": 120, - "tabWidth": 2, - "singleQuote": true, - "bracketSpacing": true, - "semi": true -} diff --git a/tests/OneThousandTokenTransfers.spec.ts b/tests/OneThousandTokenTransfers.spec.ts index a88238d..af5541b 100644 --- a/tests/OneThousandTokenTransfers.spec.ts +++ b/tests/OneThousandTokenTransfers.spec.ts @@ -1,27 +1,10 @@ -import { Blockchain, SandboxContract, TreasuryContract, internal } from '@ton/sandbox'; -import { Cell, toNano, beginCell, Address } from '@ton/core'; +import { Blockchain, SandboxContract, TreasuryContract } from '@ton/sandbox'; +import { Cell, toNano, Address } from '@ton/core'; import { JettonWallet } from '../wrappers/JettonWallet'; import { JettonMinter, jettonContentToCell } from '../wrappers/JettonMinter'; import '@ton/test-utils'; import { compile } from '@ton/blueprint'; -/* - These tests check compliance with the TEP-74 and TEP-89, - but also checks some implementation details. - If you want to keep only TEP-74 and TEP-89 compliance tests, - you need to remove/modify the following tests: - mint tests (since minting is not covered by standard) - exit_codes - prove pathway -*/ - -//jetton params - -const fwd_fee = 1804014n, - gas_consumption = 15000000n, - min_tons_for_storage = 10000000n; -//let fwd_fee = 1804014n, gas_consumption = 14000000n, min_tons_for_storage = 10000000n; - describe('[One thousand token transfers]', () => { let jwallet_code = new Cell(); let minter_code = new Cell(); @@ -96,8 +79,7 @@ describe('[One thousand token transfers]', () => { it('[One thousand token transfers] mints initial 100B supply', async () => { const initialTotalSupply = await jettonMinter.getTotalSupply(); expect(initialTotalSupply).toBe(BigInt('0')); - const user1JettonWallet = await userWallet(user1.address); - const mintResult = await jettonMinter.sendMint( + await jettonMinter.sendMint( user1.getSender(), user1.address, BigInt('100000000000'), @@ -135,7 +117,7 @@ describe('[One thousand token transfers]', () => { expect(await user3JettonWallet.getJettonBalance()).toEqual(BigInt('33000000000')); }); - it('[One thousand token transfers] do the 10.000 transfers', async () => { + it('[One thousand token transfers] do the 1.000 transfers', async () => { let i = 1; for (const transfer of transfers) { const senderJettonWallet = await userWallet(transfer.sender.address); diff --git a/tests/utils.ts b/tests/utils.ts index 9ff20dd..1b2ee53 100644 --- a/tests/utils.ts +++ b/tests/utils.ts @@ -98,7 +98,7 @@ export const parseBurnNotification = (body: Cell) => { }; const testPartial = (cmp: any, match: any) => { - for (let key in match) { + for (const key in match) { if (!(key in cmp)) { throw Error(`Unknown key ${key} in ${cmp}`); } diff --git a/wrappers/JettonMinter.ts b/wrappers/JettonMinter.ts index ccfde11..8eed35d 100644 --- a/wrappers/JettonMinter.ts +++ b/wrappers/JettonMinter.ts @@ -8,8 +8,6 @@ import { Sender, SendMode, toNano, - internal as internal_relaxed, - storeMessageRelaxed, } from '@ton/core'; import { Op } from './JettonConstants'; diff --git a/wrappers/JettonWallet.ts b/wrappers/JettonWallet.ts index bd1f3a8..1c3937e 100644 --- a/wrappers/JettonWallet.ts +++ b/wrappers/JettonWallet.ts @@ -10,9 +10,8 @@ import { toNano, } from '@ton/core'; -export type JettonWalletConfig = {}; -export function jettonWalletConfigToCell(config: JettonWalletConfig): Cell { +export function jettonWalletConfigToCell(): Cell { return beginCell().endCell(); } @@ -26,8 +25,8 @@ export class JettonWallet implements Contract { return new JettonWallet(address); } - static createFromConfig(config: JettonWalletConfig, code: Cell, workchain = 0) { - const data = jettonWalletConfigToCell(config); + static createFromConfig(config: object, code: Cell, workchain = 0) { + const data = jettonWalletConfigToCell(); const init = { code, data }; return new JettonWallet(contractAddress(workchain, init), init); }