Firstly, it is worth noting the relationship of independence to uncorrelatedness. If $\varepsilon_1,...,\varepsilon_n$ are independent, that is equivalent to saying that, for any univariate transformation function $g: \mathbb{R} \rightarrow \mathbb{R}$, you have:
$$\mathbb{Cov}(g(\varepsilon_i),g(\varepsilon_j)) = 0.$$
(And consequently, the correlation is also zero so long as the transformation leads to a non-zero variance.) So, independence between the residuals is equivalent to saying that there is zero covariance under all possible univariate transformations of the random variables. One way of looking at this is to say that zero correlation for a specific transformation $g$ is an aspect of independence. Consequently, if you want to test whether a set of random variables are independent, this is the same as testing that they are uncorrelated under a variety of univariate transformations (unfortunately an infinite variety!).
Consequently, your intuition here is quite reasonable. By testing for correlation between absolute or squared residuals, you are testing two other aspects of independence. If the residuals were independent then with sufficient data you would find zero correlation in both these tests. Now, bear in mind that there are some complications with testing multiple hypotheses on a single set of data, because you have a "multiple comparisons" problem. Moreover, in most regression/time-series models, independence of the error terms leads to residuals that are almost independent, but not quite, so you may need to think about whether you actually want to test the residuals for strict independence or not. In any case, setting aside those complicating issues, your basic idea is fine --- correlation between absolute values or squared values would entail a kind of dependence.