diff --git a/src/KafkaFlow.UnitTests/Middlewares/Serialization/SchemaRegistryTypeResolverTests.cs b/src/KafkaFlow.UnitTests/Middlewares/Serialization/SchemaRegistryTypeResolverTests.cs index dc079e896..38f720526 100644 --- a/src/KafkaFlow.UnitTests/Middlewares/Serialization/SchemaRegistryTypeResolverTests.cs +++ b/src/KafkaFlow.UnitTests/Middlewares/Serialization/SchemaRegistryTypeResolverTests.cs @@ -29,7 +29,7 @@ public async Task OnConsumeAsync_WhenCalledTwice_TypeIsResolvedOnceThenTypeIsLoa { // Arrange var expectedSchemaId = BinaryPrimitives.ReadInt32BigEndian( - ((byte[]) this.messageValue).AsSpan().Slice(1, 4)); + this.messageValue.AsSpan().Slice(1, 4)); this.schemaRegistryTypeNameResolverMock.Setup( resolver => resolver.ResolveAsync(expectedSchemaId)).ReturnsAsync(typeof(SchemaRegistryTypeResolverTests).FullName);