Skip to content

Commit f67ff16

Browse files
committed
fix: ensure global rule
1 parent 73e55f0 commit f67ff16

File tree

1 file changed

+17
-0
lines changed
  • packages/indexer-common/src/indexing-fees/__tests__

1 file changed

+17
-0
lines changed

packages/indexer-common/src/indexing-fees/__tests__/dips.test.ts

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,8 @@ import {
1313
AllocationManager,
1414
DipsCollector,
1515
TapCollector,
16+
createIndexerManagementClient,
17+
Operator,
1618
} from '@graphprotocol/indexer-common'
1719
import {
1820
connectDatabase,
@@ -102,6 +104,21 @@ const setup = async () => {
102104
metrics,
103105
)
104106
dipsCollector = network.dipsCollector!
107+
const indexerManagementClient = await createIndexerManagementClient({
108+
models: managementModels,
109+
graphNode,
110+
logger,
111+
defaults: {
112+
globalIndexingRule: {
113+
allocationAmount: parseGRT('1000'),
114+
parallelAllocations: 1,
115+
},
116+
},
117+
network,
118+
})
119+
120+
const operator = new Operator(logger, indexerManagementClient, networkSpecWithDips)
121+
await operator.ensureGlobalIndexingRule()
105122
}
106123

107124
const setupEach = async () => {

0 commit comments

Comments
 (0)