What am I doing wrong in calculating the following limit?

You say you divide by $x$, but that's not what you do in the denominator; it would be:

$$\lim_{x\to-2} \frac{x+2}{\sqrt{6+x}-2} =\lim_{x\to-2} \frac{1+\tfrac{2}{x}}{\tfrac{\sqrt{6+x}}{x}-\tfrac{2}{x}} =\lim_{x\to-2} \frac{1+\tfrac{2}{x}}{-\sqrt{\tfrac{6}{x^2}+\tfrac{1}{x}}-\tfrac{2}{x}} $$

A better approach: $$\begin{array}{rl} \displaystyle \lim_{x\to-2} \frac{x+2}{\sqrt{6+x}-2} & \displaystyle = \lim_{x\to-2} \frac{\left(x+2\right)\color{blue}{\left(\sqrt{6+x}+2\right)}}{\left(\sqrt{6+x}-2\right)\color{blue}{\left(\sqrt{6+x}+2\right)}} \\[7pt] & \displaystyle = \lim_{x\to-2} \frac{\left(x+2\right)\left(\sqrt{6+x}+2\right)}{x+2} \\[7pt] & \displaystyle = \lim_{x\to-2} \left(\sqrt{6+x}+2\right) \\ & = 4 \end{array}$$


One may set $u=x+2$, then, as $x \to -2$, we have $u \to 0$, giving $$ \frac{x+2}{\sqrt{6+x}-2}=\frac{u}{\sqrt{u+4}-2}\times\frac{\sqrt{u+4}+2}{\sqrt{u+4}+2}=\sqrt{u+4}+2 \to 4. $$


You can apply L'Hospital rule, i.e differentiating numerator and denominator functions with respect to $x$,

$$2\sqrt{x + 6} = 2 \sqrt{-2 + 6} = 4$$