Replication test

Test for the replication layer.