mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-12-23 09:52:26 +01:00
Add test to reproduce issue behavior
This commit is contained in:
parent
b6b18339e2
commit
47039cc3a9
@ -33,6 +33,25 @@ describe('Nonce Tracker', function () {
|
|||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
|
||||||
|
describe.only('issue 3670', function () {
|
||||||
|
beforeEach(function () {
|
||||||
|
const txGen = new MockTxGen()
|
||||||
|
pendingTxs = txGen.generate({ status: 'submitted' }, {
|
||||||
|
fromNonce: 6,
|
||||||
|
count: 3,
|
||||||
|
})
|
||||||
|
nonceTracker = generateNonceTrackerWith(pendingTxs, [], '0x6')
|
||||||
|
})
|
||||||
|
|
||||||
|
it('should return 9', async function () {
|
||||||
|
this.timeout(15000)
|
||||||
|
const nonceLock = await nonceTracker.getNonceLock('0x7d3517b0d011698406d6e0aed8453f0be2697926')
|
||||||
|
console.log(JSON.stringify(nonceLock, null, 2))
|
||||||
|
assert.equal(nonceLock.nextNonce, '9', `nonce should be 9 got ${nonceLock.nextNonce}`)
|
||||||
|
await nonceLock.releaseLock()
|
||||||
|
})
|
||||||
|
})
|
||||||
|
|
||||||
describe('with no previous txs', function () {
|
describe('with no previous txs', function () {
|
||||||
beforeEach(function () {
|
beforeEach(function () {
|
||||||
nonceTracker = generateNonceTrackerWith([], [])
|
nonceTracker = generateNonceTrackerWith([], [])
|
||||||
|
Loading…
Reference in New Issue
Block a user