From afae0955282144161995b6ccc2c5a6d3c7d424be Mon Sep 17 00:00:00 2001 From: Alain Nicolas Date: Fri, 20 Oct 2023 16:17:06 +0200 Subject: [PATCH] chore: Add unit test to the subgraph --- subgraph/tests/schema-registry.test.ts | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/subgraph/tests/schema-registry.test.ts b/subgraph/tests/schema-registry.test.ts index e7b28ee4..8e60032e 100644 --- a/subgraph/tests/schema-registry.test.ts +++ b/subgraph/tests/schema-registry.test.ts @@ -1,5 +1,5 @@ import { afterEach, assert, clearStore, describe, test } from "matchstick-as"; -import { BigInt, ethereum } from "@graphprotocol/graph-ts"; +import { ethereum } from "@graphprotocol/graph-ts"; import { newTypedMockEvent } from "matchstick-as/assembly/defaults"; import { handleSchemaCreated } from "../src/schema-registry"; import { SchemaCreated, SchemaCreated as SchemaCreatedEvent } from "../generated/SchemaRegistry/SchemaRegistry"; @@ -47,9 +47,7 @@ function createSchemaCreatedEvent( ): SchemaCreated { const schemaCreatedEvent = newTypedMockEvent(); - schemaCreatedEvent.parameters.push( - new ethereum.EventParam("id", ethereum.Value.fromI32(BigInt.fromString(schemaId).toI32())), - ); + schemaCreatedEvent.parameters.push(new ethereum.EventParam("id", ethereum.Value.fromString(schemaId))); schemaCreatedEvent.parameters.push(new ethereum.EventParam("name", ethereum.Value.fromString(schemaName))); schemaCreatedEvent.parameters.push( new ethereum.EventParam("description", ethereum.Value.fromString(schemaDescription)),