35 lines
1.2 KiB
Diff
35 lines
1.2 KiB
Diff
From 92f0b7927577e190137a466ffeb4ae06c428efcd Mon Sep 17 00:00:00 2001
|
|
From: bizhiyuan <bizhiyuan@kylinos.cn>
|
|
Date: Sun, 6 Aug 2023 01:12:21 +0800
|
|
Subject: [PATCH] Adjust regex to support json2.6.3 error
|
|
|
|
---
|
|
pcsd/test/test_config.rb | 4 ++--
|
|
1 file changed, 2 insertions(+), 2 deletions(-)
|
|
|
|
diff --git a/pcsd/test/test_config.rb b/pcsd/test/test_config.rb
|
|
index 7aaf434..a580b24 100644
|
|
--- a/pcsd/test/test_config.rb
|
|
+++ b/pcsd/test/test_config.rb
|
|
@@ -126,7 +126,7 @@ class TestConfig < Test::Unit::TestCase
|
|
assert_equal('error', $logger.log[0][0])
|
|
assert_match(
|
|
# the number is based on JSON gem version
|
|
- /Unable to parse pcs_settings file: \d+: unexpected token/,
|
|
+ /Unable to parse pcs_settings file: (\d+: )?unexpected token/,
|
|
$logger.log[0][1]
|
|
)
|
|
assert_equal(fixture_empty_config, cfg.text)
|
|
@@ -723,7 +723,7 @@ class TestCfgKnownHosts < Test::Unit::TestCase
|
|
assert_equal('error', $logger.log[0][0])
|
|
assert_match(
|
|
# the number is based on JSON gem version
|
|
- /Unable to parse known-hosts file: \d+: unexpected token/,
|
|
+ /Unable to parse known-hosts file: (\d+: )?unexpected token/,
|
|
$logger.log[0][1]
|
|
)
|
|
assert_empty_data(cfg)
|
|
--
|
|
2.27.0
|
|
|