public COM verifyCom(byte[] data, Class<? extends COM> type) throws RdaException {
        final COM com = read(data, type);
        if (!com.getDataGroups().containsAll(com.getRdaDataGroups())) {
            throw new RdaException(
                    RdaError.COM, String.format("Not all data groups are available: %s", com.getDataGroups())
            );
        }
        return com;
    }
@Test
    public void shouldThrowErrorIfBasicDataGroupsAreMissingFromTravelDocument() throws Exception {
        final CardVerifier verifier = verifier(null, null);
        final byte[] com = readFixture("nik2014/efCom");
        com[20] += 2;
        Exception exception = assertThrows(RdaException.class, () -> {
            verifier.verifyCom(com, TravelDocumentCOM.class);
        });
        assertEquals(RdaError.COM, ((RdaException) exception).error);
        assertEquals("Not all data groups are available: [3, 2, 15, 14]", exception.getMessage());
    }