HDFS-8310. Fix TestCLI.testAll 'help: help for find' on Windows. (Kiran Kumar M R via Xiaoyu Yao)
This commit is contained in:
parent
a583a40693
commit
7a26d174af
@ -18,6 +18,7 @@
|
||||
|
||||
package org.apache.hadoop.cli.util;
|
||||
|
||||
import org.apache.hadoop.util.Shell;
|
||||
import java.util.regex.Pattern;
|
||||
|
||||
/**
|
||||
@ -33,6 +34,10 @@ public class RegexpAcrossOutputComparator extends ComparatorBase {
|
||||
|
||||
@Override
|
||||
public boolean compare(String actual, String expected) {
|
||||
if (Shell.WINDOWS) {
|
||||
actual = actual.replaceAll("\\r", "");
|
||||
expected = expected.replaceAll("\\r", "");
|
||||
}
|
||||
return Pattern.compile(expected).matcher(actual).find();
|
||||
}
|
||||
|
||||
|
@ -632,6 +632,9 @@ Release 2.8.0 - UNRELEASED
|
||||
HDFS-8219. setStoragePolicy with folder behavior is different after cluster restart.
|
||||
(surendra singh lilhore via Xiaoyu Yao)
|
||||
|
||||
HDFS-8310. Fix TestCLI.testAll "help: help for find" on Windows.
|
||||
(Kiran Kumar M R via Xiaoyu Yao)
|
||||
|
||||
Release 2.7.1 - UNRELEASED
|
||||
|
||||
INCOMPATIBLE CHANGES
|
||||
|
Loading…
Reference in New Issue
Block a user