Class UnredactedDebugFormatForTest

java.lang.Object
com.google.protobuf.UnredactedDebugFormatForTest

public final class UnredactedDebugFormatForTest extends Object
These APIs are restricted to test-only targets, and are suitable for test purposes where it is impractical to compare protos directly via ProtoTruth (e.g. log output).
  • Constructor Details

    • UnredactedDebugFormatForTest

      private UnredactedDebugFormatForTest()
  • Method Details

    • unredactedMultilineString

      public static String unredactedMultilineString(MessageOrBuilder message)
      Like TextFormat.printer().printToString(message), but for test assertion purposes.
    • unredactedMultilineString

      public static String unredactedMultilineString(UnknownFieldSet fields)
      Like TextFormat.printer().printToString(fields), but for test assertion purposes.
    • unredactedSingleLineString

      public static String unredactedSingleLineString(MessageOrBuilder message)
      Like TextFormat.printer().emittingSingleLine(true).printToString(message), but for test assertion purposes.
    • unredactedSingleLineString

      public static String unredactedSingleLineString(UnknownFieldSet fields)
      Like TextFormat.printer().emittingSingleLine(true).printToString(fields), but for test assertion purposes.