From 945b5ac98026a0b612c037de100080b677bdc80c Mon Sep 17 00:00:00 2001 From: Bobby Iliev Date: Tue, 7 Mar 2023 22:30:35 +0200 Subject: [PATCH] Allow integration tests on PRs --- .github/workflows/integration.yaml | 4 ++-- src/schemas/schemaRegistry.ts | 6 ++---- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/.github/workflows/integration.yaml b/.github/workflows/integration.yaml index 3e6abe0..2b62bde 100644 --- a/.github/workflows/integration.yaml +++ b/.github/workflows/integration.yaml @@ -1,8 +1,8 @@ name: Integration Tests on: pull_request: - paths: - - materialize/** + branches: + - main jobs: integration: diff --git a/src/schemas/schemaRegistry.ts b/src/schemas/schemaRegistry.ts index 215b6a5..56f32a0 100644 --- a/src/schemas/schemaRegistry.ts +++ b/src/schemas/schemaRegistry.ts @@ -6,9 +6,7 @@ import alert from 'cli-alerts'; function nameHook(): any { let i = 0; return function(schema: any) { - if (schema.name) { - schema.name = `name${i++}`; - } + schema.name = `name${i++}` } } @@ -57,7 +55,7 @@ export async function registerSchema(avroSchema: any, registry: any) { return schemaId; } -export async function getAvroEncodedRecord(record: any, registry: any, schema_id: number) { +export async function getAvroEncodedRecord(record: any, registry: any, schema_id: any) { let encodedRecord = await registry.encode(schema_id, record); return encodedRecord; }