Fix proto comparison for fields mapped to type table
Original commit: 28e6219b0b
This commit is contained in:
committed by
romanart
parent
f8d8f666c9
commit
81d78949c3
+12
-2
@@ -58,10 +58,20 @@ abstract class AbstractProtoComparisonTest<PROTO_DATA> : TestWithWorkingDir() {
|
||||
|
||||
val rawProtoDifference = when {
|
||||
oldData is ClassProtoData && newData is ClassProtoData -> {
|
||||
ProtoCompareGenerated(oldData.nameResolver, newData.nameResolver).difference(oldData.proto, newData.proto)
|
||||
ProtoCompareGenerated(
|
||||
oldNameResolver = oldData.nameResolver,
|
||||
newNameResolver = newData.nameResolver,
|
||||
oldTypeTable = oldData.proto.typeTableOrNull,
|
||||
newTypeTable = newData.proto.typeTableOrNull
|
||||
).difference(oldData.proto, newData.proto)
|
||||
}
|
||||
oldData is PackagePartProtoData && newData is PackagePartProtoData -> {
|
||||
ProtoCompareGenerated(oldData.nameResolver, newData.nameResolver).difference(oldData.proto, newData.proto)
|
||||
ProtoCompareGenerated(
|
||||
oldNameResolver = oldData.nameResolver,
|
||||
newNameResolver = newData.nameResolver,
|
||||
oldTypeTable = oldData.proto.typeTableOrNull,
|
||||
newTypeTable = newData.proto.typeTableOrNull
|
||||
).difference(oldData.proto, newData.proto)
|
||||
}
|
||||
else -> null
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user