Authentication factory tests