> So if you are testing all the public methods you are at the same time testing the private methods that get called.
that's nice in theory but in practice if your API looks like
class my_algorithm {
public:
float compute_next_value(float);
private:
void deborgle_fields(...);
void reticulate_splines(...);
void deboor_network_max_span(...);
vector<float> m_tempArray1, m_tempArray2, ...;
vector<complex<double>> m_protoscalarField[3];
};
you'll have a much better time if you can test every part of the algorithm individually, even if these steps are entirely specific to this very algorithm and useless to any other code and must not be mingled with with API users under any circumstance (and thus made private)