Solution (source code)

= Solution

Because $1<p<∞$, $L^p$ is reflexive, so a bounded sequence has a weakly convergent subsequence $g_{j_k}\rightharpoonup g$. Then
$$
|\int g_{j_k}(h_k-h)|\leq K\|h_k-h\|_q\to0,
$$
and weak convergence handles $\int g_{j_k}h$. Thus the displayed limit holds (with the evident OCR correction $\int gh$ on the right).

Strong convergence of the tests is essential: in $L^2(0,2π)$ take the same orthonormal sequence for $g_j$ and $h_j$. Both converge weakly to zero, but $\int g_jh_j=1$.