The functions $f(x) = 1/x$ and $f(x) = 1/x^2$ are not defined in $0$. So in particular it makes no sense to think about continuity or differentiability at $0$. Both your statement hold only on intervals.
Differentiability does not imply continuity on an interval! Consider the somewhat artificial functions defined as $0$ on the rationals and $x^2$ on the irrationals. It is continuous and differentiable at $0$ and neither continuous nor differentiable on $\mathbb{R} \setminus \{0\}$.
Edit: I think I misunderstood the "on an interval" part. Anyway, the implication is pointwise.
The issue here is that the derivative $y'(1)$ is not defined. I'll start with the definition and then discuss why the differentiation rules don't apply at $x = 1$. First, for the derivative to exist at $x = 1$, then by definition,the following limit has to exist:
$$\lim_{h\to 0}\frac{y(1+h) - y(1)}{h} \tag{1}.$$
Now, in order for $(1)$ to exist the left and right limits have to exist and agree. So, we can look at the left and right derivatives:
Right Derivative:
$$y'_{+}(1) = \lim_{h\to 0^{+}}\frac{f(1+h) - f(1)}{h} = \lim_{h\to 0^{+}}\frac{2(1+h) - 2}{h} = \lim_{h\to 0^{+}}\frac{2h}{h} = 2$$
There's no trouble there, however we run into problems with the left derivative:
Left Derivative:
\begin{align}
y'_{-}(1)&=\lim_{h\to 0^{-}}\frac{y(1+h) - y(1)}{h}\\
&= \lim_{h\to 0^{-}}\frac{(1+h)^2 - 2}{h}\\
&= \lim_{h\to 0^{-}}\frac{1 +2h+h^2-2}{h}\\
&= \lim_{h\to 0^{-}}\frac{h^2+2h-1}{h}\\
&= \lim_{h\to 0^{-}}\left(h + 2 - \frac{1}{h}\right)\\
&= \infty
\end{align}
So, since the left and right derivatives don't agree, we can say that $y$ is not differentiable at $y = 1$. As has been pointed out in the comments we could also have concluded that from continuity, because if $y'(1)$ had existed, then $y$ would need to be continuous at $x = 1$, and because it is not we can immediately rule out differentiability there.
Now, to understand why it doesn't work to take the derivatives of $2x$ and $x^2$ and take a limit, we start by noting that we can certainly write
$$y'(x) = \begin{cases}
2x,&-\infty<x<1\\
2, &1<x<\infty
\end{cases}$$
However, if we were to write $$y'(1) = \lim_{x\to 1}y'(x)$$ we would be making two unfounded assumptions:
First, that $y$ is actually differentiable at $x = 1$, and so writing $y'(1)$ makes sense, and second that $y'$ is continuous. We don't know a priori that either of those things are true, and in fact as previously mentioned, we know that $y'(1)$ can't exist because $y$ isn't continuous at $x = 1$.
To give a bit more of an intuitive explanation, remember that the derivative at a point relies on the value of the function at that point. So, when we use $2x$ for the derivative on the left, instead of using $y(1) = 2$, which lies on the right piece, we're really using $\lim_{x\to 1^{-}}y(x) = 1$ on the left piece.
Best Answer
Yes, there is a theorem which says that if a function $f$ is differentiable at some point in its domain, then it is continuous at that point. However, this is not a very useful result for checking differentiability—it is useful for showing that a function is not differentiable (i.e. if $f$ is discontinuous at $a$, then $f$ is certainly not differentiable at $a$). This theorem is a bit of a red herring with respect to the function defined on $\mathbb{R}$ by the formula $$f(x) = \lvert \cos(x)\rvert,$$ since $f$ is continuous on $\mathbb{R}$.
Indeed, it isn't too hard to see that $f$ is continuous: there is a another theorem which states that the composition of continuous functions is continuous, and $f$ is the composition of the functions $g$ and $h$, given by the formulae $$ g(x) = \lvert x \rvert \qquad\text{and}\qquad h(x) = \cos(x) $$ (that is, $f = g\circ h$). Both $g$ and $h$ are continuous, so $f$ is continuous as well.
But, again, continuity is a bit of a red herring here.
The cosine function is periodic with period $2\pi$, from which it follows that the function $f$, defined by $f(x) = \lvert \cos(x)\rvert$, is $2\pi$-periodic. Thus, in order to determine the differentiability of $f$ on $\mathbb{R}$, it is sufficient to show that it is differentiable on the closed interval $[0,2\pi]$.
if $x \in [0,\pi/2) \cup (3\pi/2,2\pi]$, then $\cos(x) > 0$, from which it follows that \begin{align*} f(x) = \lvert \cos(x) \rvert = \cos(x) \implies f'(x) = \frac{\mathrm{d}}{\mathrm{d}x} \cos(x) = \sin(x). \end{align*}
if $x \in (\pi/2,3\pi/2)$, then $\cos(x) < 0$, from which it follows that \begin{align*} f(x) = \lvert \cos(x) \rvert = -\cos(x) \implies f'(x) = -\frac{\mathrm{d}}{\mathrm{d}x} \cos(x) = -\sin(x). \end{align*}
if $x = \pi/2$ or $x = 3\pi/2$, then $\cos(x) = 0$, and there is a bit of a problem using known derivatives to compute $f'$, since $\cos$ is being composed with the absolute value, which is not differentiable when $x=0$. It is not automatically true that $f$ is not differentiable, which means that something needs to be done to determine whether or not $f$ is differentiable here.
In general, I prefer to use more elementary tools for a problem like this, so recall the definition of the derivative: if the derivative of $f$ exists, then it is given by a limit (and if that limit doesn't exist, then the derivative does not exit). Evaluating the limit (and abusing notation a bit) gives \begin{align} \lim_{h\to 0} \frac{f(\pi/2 + h) - f(\pi/2)}{h} &= \lim_{h\to 0} \frac{\lvert \cos(\pi/2+h) \rvert - \lvert \cos(\pi/2) \rvert}{h} \\ &= \begin{cases} \displaystyle \lim_{h\to 0} \frac{\cos(\pi/2+h) - 0}{h} & \text{if $0<h$, and} \\[2ex] \displaystyle \lim_{h\to 0} \frac{-\cos(\pi/2+h) - 0}{h} & \text{if $0>h$,} \end{cases} \\ &= \begin{cases} 1 & \text{if $0<h$, and} \\ -1 & \text{if $0>h$.} \end{cases} \end{align} The left-hand and right-hand limits disagree, so the limit does not exist. Therefore $f$ is not differentiable at $\pi/2$. By similar reasoning, it fails to be differentiable at $3\pi/2$, or at either of these points plus an even multiple of $\pi$.
It is often helpful to look at the graph of a function when trying to work out differentiability of a function. This is not a rigorous approach, but the graph can give insight into where one should focus their attention. In the case of $\lvert \cos(x)\rvert$, the graph is given by
A differentiable function must be "smooth"—it does not have "cusps" or "corners". The graph of this function has cusps at odd multiples of $\pi/2$, which suggests that this function is not differentiable at these points. This further suggests that when trying to determine whether or not this function is differentiable, one should focus their attention on these cusp points.