testing library

A passport or identity card chip in memory, to test an application without a document or reader.

import 'package:eid_icao/eid_icao.dart';
import 'package:eid_icao/testing.dart';

final chip = SimulatedIcaoChip();
final document = await IcaoReader(chip).read(access: chip.canKey);

Classes

SimulatedIcaoChip
A passport or identity card chip in memory that answers the commands of a real one, to test without a document or reader. Pass it wherever a CardTransport goes:

Enums

SimulatedChipAccess
How a simulated chip may be opened.
SimulatedChipProof
How a simulated chip proves it is genuine.

Properties

specimenPhoto → Uint8List
The face of the simulated document: a 200 by 260 JPEG of a person who does not exist.
final
specimenPhotoJpeg2000 → Uint8List
The same face as specimenPhoto in JPEG 2000, a JP2 file of 200 by 260 as most identity cards hold it. Pass it as the photo of a SimulatedIcaoChip to test that path.
final