Add mongo tests
Updated exist flagging