Until now I thought that the significance level and the confidence interval were the complement of each other, i.e. when some question asked me to carry out a hypothesis test with a $p %$ significance level I would construct a $(1-p)$ confidence interval and see if it englobes or not the null hypothesis.
However I was making a problem along the following lines that made me doubt some of my concepts:
The problem gave me some random variable probability density function and some sample values and asked to carry out hypothesis test for $H_0:\theta=1$ and $H_a:\theta\neq1$ at the $5\%$ significance level. Since the alternative hypothesis is a composite one I used the likelihood ratio test together with the maximum likelihood to find a relation in the form
Since the pdf was a very unusual one I used Wilks' theorem and approximated it asymptotically by a $\chi^ 2$ distribution with 1 degree of freedom, so I could have a value of $k$ that represented the significance level I wanted.
Until now everything went smoothly. However in the next part of the problem it asks me to outline briefly how I might obtain a $95\%$ confidence interval for $\theta$. Correct me if I am wrong but this wasn't what I made in the last example?
Feel free to not only explain this specific problem in particular but to also give me a broader definition of the confidence interval and significance level.
Sorry if I made any silly mistake. I started to study statistical inference in the last couple of weeks and I am still struggling even with its most simply definitions.