use of fr.neatmonster.nocheatplus.permissions.PermissionRegistry in project NoCheatPlus by NoCheatPlus.
the class TestActions method testOptimizedLogActionEmpty.
@Test
public void testOptimizedLogActionEmpty() {
PluginTests.setUnitTestNoCheatPlusAPI(false);
PermissionRegistry pReg = NCPAPIProvider.getNoCheatPlusAPI().getPermissionRegistry();
final ConfigFile config = new DefaultConfig();
config.set("actions", "log:dummy:0:0:icf");
config.set("strings.dummy", "dummy");
config.set(ConfPaths.LOGGING_ACTIVE, false);
ActionList actionList = config.getOptimizedActionList("actions", pReg.getOrRegisterPermission("dummy"));
Action<ViolationData, ActionList>[] actions = actionList.getActions(0.0);
if (actions.length != 0) {
fail("Wrong number of actions.");
}
}
Aggregations