diff options
author | Petteri Aimonen <jpa@git.mail.kapsi.fi> | 2023-06-26 09:07:08 +0300 |
---|---|---|
committer | Petteri Aimonen <jpa@git.mail.kapsi.fi> | 2023-06-26 09:08:25 +0300 |
commit | d7f388ff6317e207d7ddcd224b45a86bb7feb7a7 (patch) | |
tree | e55d0b0dddb5916488024e4da09380e6eb04172e | |
parent | 75751dff32aa8f1a26ed57e39803f96e287c83b7 (diff) |
Test cases: fix broken version check for libprotoc 23.1.
Protoc version number seems to have dropped the last number,
match only first two in the regexp.
-rw-r--r-- | tests/proto3_optional/SConscript | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/proto3_optional/SConscript b/tests/proto3_optional/SConscript index f8a5b5c..520ae74 100644 --- a/tests/proto3_optional/SConscript +++ b/tests/proto3_optional/SConscript @@ -6,8 +6,8 @@ import re version = None if 'PROTOC_VERSION' in env: - match = re.search('([0-9]+).([0-9]+).([0-9]+)', env['PROTOC_VERSION']) - version = (int(match.group(1)), int(match.group(2)), int(match.group(3))) + match = re.search('([0-9]+).([0-9]+)', env['PROTOC_VERSION']) + version = (int(match.group(1)), int(match.group(2))) # Oneof is supported by protoc >= 3.12.0 if env.GetOption('clean') or (version and (version[0] > 3 or (version[0] == 3 and version[1] >= 12))): |