YARN-4566. Fix test failure in TestMiniYarnClusterNodeUtilization. (Takashi Ohnishi via rohithsharmaks)

(cherry picked from commit e0b14f26f5)

Conflicts:

	hadoop-yarn-project/CHANGES.txt
This commit is contained in:
Jason Lowe 2016-08-15 19:45:45 +00:00
parent 1a38dd9cee
commit 74831973cb
1 changed files with 4 additions and 2 deletions

View File

@ -214,8 +214,10 @@ public class TestMiniYarnClusterNodeUtilization {
// We check if the nodeUtilization is up to date
for (int i=0; i<100; i++) {
for (RMNode ni : rmContext.getRMNodes().values()) {
if (ni.getNodeUtilization().equals(nodeUtilization)) {
break;
if (ni.getNodeUtilization() != null) {
if (ni.getNodeUtilization().equals(nodeUtilization)) {
break;
}
}
}
Thread.sleep(100);