### Question:
DefaultEntityResourceActionLister implements EntityResourceActionLister, Initializable { @Override public List<String> listActions() { List<String> actionNames = new ArrayList<>(this.strutsActionNames); try { Map<String, ResourceReferenceHandler<EntityResourceAction>> componentMap = this.contextComponentManagerProvider.get().getInstanceMap( new DefaultParameterizedType(null, ResourceReferenceHandler.class, EntityResourceAction.class)); for (String key : componentMap.keySet()) { actionNames.add(key); } } catch (ComponentLookupException e) { throw new RuntimeException("Failed to locate Resource Reference Handlers", e); } return actionNames; }  @Override void initialize(); @Override List<String> listActions();  }### Answer:
@Test public void listActions() throws Exception { Environment environment = this.mocker.getInstance(Environment.class); when(environment.getResourceAsStream("/WEB-INF/struts-config.xml")).thenReturn( getClass().getClassLoader().getResourceAsStream("WEB-INF/struts-config.xml")); this.mocker.registerMockComponent(new DefaultParameterizedType(null, ResourceReferenceHandler.class, EntityResourceAction.class), "testaction"); assertThat(this.mocker.getComponentUnderTest().listActions(), hasItems("view", "edit", "get", "testaction")); }