@sentio/cli 3.8.0-rc.4 → 3.9.0-rc.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/index.js +68198 -43258
- package/package.json +11 -4
- package/src/abi.ts +135 -2
- package/templates/sui/abis/sui/testnet/0x1e2b124f746a339b3cf99b9f969393a96594519aafb1d06517aacfeeae20e7a5.json +303 -227
- package/templates/sui/abis/sui/testnet/0xebaa2ad3eacc230f309cd933958cc52684df0a41ae7ac214d186b80f830867d2.json +12844 -10000
- package/templates/sui/src/processor.ts +1 -1
- package/templates/aptos/src/processor.test.ts +0 -16
- package/templates/eth/src/processor.test.ts +0 -30
- package/templates/fuel/src/processor.test.ts +0 -16
- package/templates/iota/src/processor.test.ts +0 -16
- package/templates/raw/src/processor.test.ts +0 -16
- package/templates/solana/src/processor.test.ts +0 -16
- package/templates/sui/src/processor.test.ts +0 -16
|
@@ -6,7 +6,7 @@ import { single_collateral } from './types/sui/testnet/0xebaa2ad3eacc230f309cd93
|
|
|
6
6
|
|
|
7
7
|
validator.bind({ network: SuiNetwork.TEST_NET }).onEventStakingRequestEvent(
|
|
8
8
|
(evt, ctx) => {
|
|
9
|
-
const amount_original = BigInt((evt.
|
|
9
|
+
const amount_original = BigInt((evt.json as any).amount)
|
|
10
10
|
const amount = evt.data_decoded.amount
|
|
11
11
|
ctx.meter.Counter('amount').add(amount, { pool: evt.data_decoded.pool_id })
|
|
12
12
|
},
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import assert from 'assert'
|
|
2
|
-
import { before, describe, test } from 'node:test'
|
|
3
|
-
import { TestProcessorServer } from '@sentio/sdk/testing'
|
|
4
|
-
|
|
5
|
-
describe('Test Processor', () => {
|
|
6
|
-
const service = new TestProcessorServer(() => import('./processor.js'))
|
|
7
|
-
|
|
8
|
-
before(async () => {
|
|
9
|
-
await service.start()
|
|
10
|
-
})
|
|
11
|
-
|
|
12
|
-
test('has config', async () => {
|
|
13
|
-
const config = await service.getConfig({})
|
|
14
|
-
assert.ok(config.contractConfigs.length > 0)
|
|
15
|
-
})
|
|
16
|
-
})
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
import assert from 'assert'
|
|
2
|
-
import { before, describe, test } from 'node:test'
|
|
3
|
-
import { TestProcessorServer, firstCounterValue } from '@sentio/sdk/testing'
|
|
4
|
-
import { mockTransferLog } from '@sentio/sdk/eth/builtin/erc20'
|
|
5
|
-
|
|
6
|
-
describe('Test Processor', () => {
|
|
7
|
-
const service = new TestProcessorServer(() => import('./processor.js'))
|
|
8
|
-
|
|
9
|
-
before(async () => {
|
|
10
|
-
await service.start()
|
|
11
|
-
})
|
|
12
|
-
|
|
13
|
-
test('has valid config', async () => {
|
|
14
|
-
const config = await service.getConfig({})
|
|
15
|
-
assert(config.contractConfigs.length > 0)
|
|
16
|
-
})
|
|
17
|
-
|
|
18
|
-
test('check transfer event handling', async () => {
|
|
19
|
-
const resp = await service.eth.testLog(
|
|
20
|
-
mockTransferLog('0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2', {
|
|
21
|
-
from: '0x0000000000000000000000000000000000000000',
|
|
22
|
-
to: '0xb329e39ebefd16f40d38f07643652ce17ca5bac1',
|
|
23
|
-
value: 10n ** 18n * 10n
|
|
24
|
-
})
|
|
25
|
-
)
|
|
26
|
-
|
|
27
|
-
const tokenCounter = firstCounterValue(resp.result, 'token')
|
|
28
|
-
assert.equal(tokenCounter, 10n)
|
|
29
|
-
})
|
|
30
|
-
})
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import assert from 'assert'
|
|
2
|
-
import { before, describe, test } from 'node:test'
|
|
3
|
-
import { TestProcessorServer } from '@sentio/sdk/testing'
|
|
4
|
-
|
|
5
|
-
describe('Test Processor', () => {
|
|
6
|
-
const service = new TestProcessorServer(async () => await import('./processor.js'))
|
|
7
|
-
|
|
8
|
-
before(async () => {
|
|
9
|
-
await service.start()
|
|
10
|
-
})
|
|
11
|
-
|
|
12
|
-
test('has config', async () => {
|
|
13
|
-
const config = await service.getConfig({})
|
|
14
|
-
assert(config.contractConfigs.length > 0)
|
|
15
|
-
})
|
|
16
|
-
})
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import assert from 'assert'
|
|
2
|
-
import { before, describe, test } from 'node:test'
|
|
3
|
-
import { TestProcessorServer } from '@sentio/sdk/testing'
|
|
4
|
-
|
|
5
|
-
describe('Test Processor', () => {
|
|
6
|
-
const service = new TestProcessorServer(async () => await import('./processor.js'))
|
|
7
|
-
|
|
8
|
-
before(async () => {
|
|
9
|
-
await service.start()
|
|
10
|
-
})
|
|
11
|
-
|
|
12
|
-
test('has config', async () => {
|
|
13
|
-
const config = await service.getConfig({})
|
|
14
|
-
assert(config.contractConfigs.length > 0)
|
|
15
|
-
})
|
|
16
|
-
})
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import assert from 'assert'
|
|
2
|
-
import { before, describe, test } from 'node:test'
|
|
3
|
-
import { TestProcessorServer } from '@sentio/sdk/testing'
|
|
4
|
-
|
|
5
|
-
describe('Test Processor', () => {
|
|
6
|
-
const service = new TestProcessorServer(() => import('./processor.js'))
|
|
7
|
-
|
|
8
|
-
before(async () => {
|
|
9
|
-
await service.start()
|
|
10
|
-
})
|
|
11
|
-
|
|
12
|
-
test('has valid config', async () => {
|
|
13
|
-
// const config = await service.getConfig({})
|
|
14
|
-
// assert(config.contractConfigs.length > 0)
|
|
15
|
-
})
|
|
16
|
-
})
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import assert from 'assert'
|
|
2
|
-
import { before, describe, test } from 'node:test'
|
|
3
|
-
import { TestProcessorServer } from '@sentio/sdk/testing'
|
|
4
|
-
|
|
5
|
-
describe('Test Processor', () => {
|
|
6
|
-
const service = new TestProcessorServer(() => import('./processor.js'))
|
|
7
|
-
|
|
8
|
-
before(async () => {
|
|
9
|
-
await service.start()
|
|
10
|
-
})
|
|
11
|
-
|
|
12
|
-
test('has valid config', async () => {
|
|
13
|
-
const config = await service.getConfig({})
|
|
14
|
-
assert.ok(config.contractConfigs.length > 0)
|
|
15
|
-
})
|
|
16
|
-
})
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import assert from 'assert'
|
|
2
|
-
import { before, describe, test } from 'node:test'
|
|
3
|
-
import { TestProcessorServer } from '@sentio/sdk/testing'
|
|
4
|
-
|
|
5
|
-
describe('Test Processor', () => {
|
|
6
|
-
const service = new TestProcessorServer(async () => await import('./processor.js'))
|
|
7
|
-
|
|
8
|
-
before(async () => {
|
|
9
|
-
await service.start()
|
|
10
|
-
})
|
|
11
|
-
|
|
12
|
-
test('has config', async () => {
|
|
13
|
-
const config = await service.getConfig({})
|
|
14
|
-
assert(config.contractConfigs.length > 0)
|
|
15
|
-
})
|
|
16
|
-
})
|