|
@@ -90,6 +90,9 @@ public class TestRMAdminService {
|
|
fs.delete(tmpDir, true);
|
|
fs.delete(tmpDir, true);
|
|
fs.mkdirs(workingPath);
|
|
fs.mkdirs(workingPath);
|
|
fs.mkdirs(tmpDir);
|
|
fs.mkdirs(tmpDir);
|
|
|
|
+
|
|
|
|
+ // reset the groups to what it default test settings
|
|
|
|
+ MockUnixGroupsMapping.resetGroups();
|
|
}
|
|
}
|
|
|
|
|
|
@After
|
|
@After
|
|
@@ -785,12 +788,7 @@ public class TestRMAdminService {
|
|
private static class MockUnixGroupsMapping implements
|
|
private static class MockUnixGroupsMapping implements
|
|
GroupMappingServiceProvider {
|
|
GroupMappingServiceProvider {
|
|
|
|
|
|
- @SuppressWarnings("serial")
|
|
|
|
- private static List<String> group = new ArrayList<String>() {{
|
|
|
|
- add("test_group_A");
|
|
|
|
- add("test_group_B");
|
|
|
|
- add("test_group_C");
|
|
|
|
- }};
|
|
|
|
|
|
+ private static List<String> group = new ArrayList<String>();
|
|
|
|
|
|
@Override
|
|
@Override
|
|
public List<String> getGroups(String user) throws IOException {
|
|
public List<String> getGroups(String user) throws IOException {
|
|
@@ -813,6 +811,13 @@ public class TestRMAdminService {
|
|
group.add("test_group_E");
|
|
group.add("test_group_E");
|
|
group.add("test_group_F");
|
|
group.add("test_group_F");
|
|
}
|
|
}
|
|
|
|
+
|
|
|
|
+ public static void resetGroups() {
|
|
|
|
+ group.clear();
|
|
|
|
+ group.add("test_group_A");
|
|
|
|
+ group.add("test_group_B");
|
|
|
|
+ group.add("test_group_C");
|
|
|
|
+ }
|
|
}
|
|
}
|
|
|
|
|
|
}
|
|
}
|