Testing and consistency checking with labels