File: python3.12.diff

package info (click to toggle)
protobuf 3.21.12-13
  • links: PTS
  • area: main
  • in suites: forky, sid
  • size: 42,964 kB
  • sloc: cpp: 179,373; java: 88,098; objc: 60,661; ansic: 37,810; cs: 28,526; python: 22,516; php: 11,464; ruby: 6,127; sh: 3,635; makefile: 3,341; pascal: 2,352; xml: 2,317; javascript: 311; lisp: 87; awk: 17
file content (22 lines) | stat: -rw-r--r-- 1,150 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
Index: b/python/google/protobuf/internal/json_format_test.py
===================================================================
--- a/python/google/protobuf/internal/json_format_test.py
+++ b/python/google/protobuf/internal/json_format_test.py
@@ -1043,7 +1043,7 @@ class JsonFormatTest(JsonFormatBase):
   def testInvalidTimestamp(self):
     message = json_format_proto3_pb2.TestTimestamp()
     text = '{"value": "10000-01-01T00:00:00.00Z"}'
-    self.assertRaisesRegexp(
+    self.assertRaisesRegex(
         json_format.ParseError, 'Failed to parse value field: '
         'time data \'10000-01-01T00:00:00\' does not match'
         ' format \'%Y-%m-%dT%H:%M:%S\' at TestTimestamp.value.',
@@ -1080,7 +1080,7 @@ class JsonFormatTest(JsonFormatBase):
   def testInvalidOneof(self):
     message = json_format_proto3_pb2.TestOneof()
     text = '{"oneofInt32Value": 1, "oneofStringValue": "2"}'
-    self.assertRaisesRegexp(
+    self.assertRaisesRegex(
         json_format.ParseError, 'Message type "proto3.TestOneof"'
         ' should not have multiple "oneof_value" oneof fields at "TestOneof".',
         json_format.Parse, text, message)