@Override
    public AppResponse process(Flow flow, AppRequest request) throws FlowNotDefinedException, IOException, NoSuchAlgorithmException {
        var response = new WidPollResponse(attestEnabled && Arrays.asList(allowedActions).contains(appSession.getAction()));

        setValid(false);

        switch (appSession.getState()) {
            case "VERIFIED" -> {
                if (validateCardStatus()) {
                    setValid(true);
                    response.setStatus(appSession.getState());
                }
            }
            case "COMPLETED", "AUTHENTICATED", "CONFIRMED", "CANCELLED", "ABORTED" -> response.setStatus(appSession.getState());
            default -> response.setStatus("PENDING");
        }

        if ("ABORTED".equals(appSession.getState())) {
            response.setStatus("ABORTED");
            response.setError(appSession.getError());
        }

        return response;
    }
@Test
    void processAttestDisabled() throws FlowNotDefinedException, IOException, NoSuchAlgorithmException {
        setupWidPolling(false);

        WidPollResponse appResponse = (WidPollResponse) widPolling.process(mockedFlow, mockedAbstractAppRequest);

        assertFalse(appResponse.getAttestApp());
        assertEquals("PENDING", appResponse.getStatus());
    }