Skip to content

[Feature] Do conformance tests via property testing #26

@Dogacel

Description

@Dogacel

Is your feature request related to a problem? Please describe.
Currently our generated code for proto2, proto2_editions, proto3_editions, editions2023 is not thoroughly tested. Because I have initially created this plugin for proto3 classes and did not account for editions support. We should write better tests to chekc serialization/deserialization format.

Describe the solution you'd like
Use https://github.com/dogacel/kotest-property-protobuf to test serialization/deserialization throughly.

Describe alternatives you've considered
Manual testing is useful for inspecting generated class signatures. However it is not feasible for testing all serde features, especially if you want to cover proto2, 3 and related editions.

My idea is that if property testing can prove serde works fine in generated classes, it proves generated classes are a true reflection of the proto definitions. We only need manual inspection + unit tests for following,

  1. Stylistic reasons, improve generated class signature and design for developer experience.
  2. Edge cases, conformance tests do not test generation of various message shapes, it only tests field shapes and serialization/deserialization.

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions