moved expected checksum in separate function