fix bug in spec helper