Can we test if a number is a lucky number in polynomial time? I know primality tests exist in polynomial time. But can we test if a number is a lucky number in polynomial time ?

I doubt you're going to get a satisfactory answer to this question. I'm fairly sure the answer to your question is that there's no known polynomial time algorithm to determine if a number is lucky. The fact that Primes is in P was not shown until 2004, when people have been studying prime numbers and prime number tests for quite a long time. I certainly can't comment on whether or not there is a polynomial time algorithm for lucky numbers, probably it's in $\mathrm{NP}$ so such a question would inevitably have to answer $\mathrm{P=NP}$. 
Looking at the lucky numbers they seem to have much less exploitable structure than the primes. Possibly one could develop a large theory of lucky numbers and then use this to help make progress forward. But examining the seive algorithm I highly doubt there's going to be a way to make it polynomial in terms of the input. 
