Primality test for numbers of the form $(2p)^{2^n}+1$