If heat transport is mainly by diffusion (conduction), a general definition of heat transport is:
$$\left.q\right|_w=-k \left. {{dT}\over{dx}}\right|_w = h\left(\left.T\right|_w-T_f\right)$$
The subscript $w$ implies that the derivative and the temperature is defined at the wall. Furthermore, by convention, it is assumed the temperature difference is positive, i.e. the wall temperature is higher than the fluid temperature.
If the heat flux is unknown but you are able to measure the temperature field then you may calculate the Nusselt number through:
$$\mathrm{Nu}=\frac{hL}{k}=-\frac{L}{\left.T\right|_w-T_f}\left.{{dT}\over{dx}}\right|_w$$
Another way is to use you original equation and measure the heat input into the system by a heat balance. This is done by integrating the total energy at the entrance (usually known from boundary conditions, i.e. imposed enthalpy, temperature, etc.), the total energy at the outlet and finding the difference which must be the energy input into the system by the walls. This, divided by the heat transport surface area, gives you the mean heat flux and from it can be determined a mean Nusselt number.