YARN-605. Fix failing unit test in TestNMWebServices when versionInfo has parantheses like when running on a git checkout. Contributed by Hitesh Shah.
svn merge --ignore-ancestry -c 1471608 ../../trunk/ git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/branches/branch-2@1471609 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
2dbf0c2af5
commit
909e52274c
|
@ -222,6 +222,9 @@ Release 2.0.5-beta - UNRELEASED
|
||||||
YARN-549. YarnClient.submitApplication should wait for application to be
|
YARN-549. YarnClient.submitApplication should wait for application to be
|
||||||
accepted by the RM (Zhijie Shen via bikas)
|
accepted by the RM (Zhijie Shen via bikas)
|
||||||
|
|
||||||
|
YARN-605. Fix failing unit test in TestNMWebServices when versionInfo has
|
||||||
|
parantheses like when running on a git checkout. (Hitesh Shah via vinodkv)
|
||||||
|
|
||||||
Release 2.0.4-alpha - UNRELEASED
|
Release 2.0.4-alpha - UNRELEASED
|
||||||
|
|
||||||
INCOMPATIBLE CHANGES
|
INCOMPATIBLE CHANGES
|
||||||
|
|
|
@ -85,5 +85,10 @@ public class WebServicesTestUtils {
|
||||||
got.contains(expected));
|
got.contains(expected));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static void checkStringEqual(String print, String expected, String got) {
|
||||||
|
assertTrue(
|
||||||
|
print + " is not equal, got: " + got + " expected: " + expected,
|
||||||
|
got.equals(expected));
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -360,14 +360,14 @@ public class TestNMWebServices extends JerseyTest {
|
||||||
|
|
||||||
WebServicesTestUtils.checkStringMatch("hadoopVersionBuiltOn",
|
WebServicesTestUtils.checkStringMatch("hadoopVersionBuiltOn",
|
||||||
VersionInfo.getDate(), hadoopVersionBuiltOn);
|
VersionInfo.getDate(), hadoopVersionBuiltOn);
|
||||||
WebServicesTestUtils.checkStringMatch("hadoopBuildVersion",
|
WebServicesTestUtils.checkStringEqual("hadoopBuildVersion",
|
||||||
VersionInfo.getBuildVersion(), hadoopBuildVersion);
|
VersionInfo.getBuildVersion(), hadoopBuildVersion);
|
||||||
WebServicesTestUtils.checkStringMatch("hadoopVersion",
|
WebServicesTestUtils.checkStringMatch("hadoopVersion",
|
||||||
VersionInfo.getVersion(), hadoopVersion);
|
VersionInfo.getVersion(), hadoopVersion);
|
||||||
|
|
||||||
WebServicesTestUtils.checkStringMatch("resourceManagerVersionBuiltOn",
|
WebServicesTestUtils.checkStringMatch("resourceManagerVersionBuiltOn",
|
||||||
YarnVersionInfo.getDate(), resourceManagerVersionBuiltOn);
|
YarnVersionInfo.getDate(), resourceManagerVersionBuiltOn);
|
||||||
WebServicesTestUtils.checkStringMatch("resourceManagerBuildVersion",
|
WebServicesTestUtils.checkStringEqual("resourceManagerBuildVersion",
|
||||||
YarnVersionInfo.getBuildVersion(), resourceManagerBuildVersion);
|
YarnVersionInfo.getBuildVersion(), resourceManagerBuildVersion);
|
||||||
WebServicesTestUtils.checkStringMatch("resourceManagerVersion",
|
WebServicesTestUtils.checkStringMatch("resourceManagerVersion",
|
||||||
YarnVersionInfo.getVersion(), resourceManagerVersion);
|
YarnVersionInfo.getVersion(), resourceManagerVersion);
|
||||||
|
|
|
@ -293,14 +293,14 @@ public class TestRMWebServices extends JerseyTest {
|
||||||
|
|
||||||
WebServicesTestUtils.checkStringMatch("hadoopVersionBuiltOn",
|
WebServicesTestUtils.checkStringMatch("hadoopVersionBuiltOn",
|
||||||
VersionInfo.getDate(), hadoopVersionBuiltOn);
|
VersionInfo.getDate(), hadoopVersionBuiltOn);
|
||||||
WebServicesTestUtils.checkStringMatch("hadoopBuildVersion",
|
WebServicesTestUtils.checkStringEqual("hadoopBuildVersion",
|
||||||
VersionInfo.getBuildVersion(), hadoopBuildVersion);
|
VersionInfo.getBuildVersion(), hadoopBuildVersion);
|
||||||
WebServicesTestUtils.checkStringMatch("hadoopVersion",
|
WebServicesTestUtils.checkStringMatch("hadoopVersion",
|
||||||
VersionInfo.getVersion(), hadoopVersion);
|
VersionInfo.getVersion(), hadoopVersion);
|
||||||
|
|
||||||
WebServicesTestUtils.checkStringMatch("resourceManagerVersionBuiltOn",
|
WebServicesTestUtils.checkStringMatch("resourceManagerVersionBuiltOn",
|
||||||
YarnVersionInfo.getDate(), resourceManagerVersionBuiltOn);
|
YarnVersionInfo.getDate(), resourceManagerVersionBuiltOn);
|
||||||
WebServicesTestUtils.checkStringMatch("resourceManagerBuildVersion",
|
WebServicesTestUtils.checkStringEqual("resourceManagerBuildVersion",
|
||||||
YarnVersionInfo.getBuildVersion(), resourceManagerBuildVersion);
|
YarnVersionInfo.getBuildVersion(), resourceManagerBuildVersion);
|
||||||
WebServicesTestUtils.checkStringMatch("resourceManagerVersion",
|
WebServicesTestUtils.checkStringMatch("resourceManagerVersion",
|
||||||
YarnVersionInfo.getVersion(), resourceManagerVersion);
|
YarnVersionInfo.getVersion(), resourceManagerVersion);
|
||||||
|
|
Loading…
Reference in New Issue