Yes, the "work done by the battery" and "the thermal energy developed" represent two names of the same physical quantity. The work done by the battery on the resistor is dissipated by the resistor in the form of thermal energy. Hence the " work done by the battery " and " the thermal energy developed " represent two names of the same physical quantity.
However, a non-ideal battery, in this case, would have to do extra work in order to overcome the internal resistance of the battery. Hence, the work done by a non-ideal battery will not be equal to the thermal energy developed.