Start of expect code to test setup

Needs to be robust so that it will delete the entity if it already exists at the start (ie, not permafail).