@Override
    public Map<String, Object> getVariables() {
        final Map<String, Object> collectedVariables = new HashMap<>();

        if (parent != null) {
            collectedVariables.putAll(parent.getVariables());
        }
        variables.forEach(collectedVariables::put);
        return collectedVariables;
    }
@Test
    public void testGetVariables() {
        ProcessContextImpl context = new ProcessContextImpl();
        ProcessContextImpl parentContext = new ProcessContextImpl();
        parentContext.setVariable("key", "value");
        context.setParent(parentContext);
        Assertions.assertEquals(1, context.getVariables().size());
    }