Dear Martin,
consequential criticism of astrologers can be found in the context of a general criticism directed against the power of fate (daiva) and the believers in fate in the Mokṣopāya, chapters II.4-9.
There, I am aware of two direct references to astrologers (see below), but implicit criticism of daiva and °jñas is also palpable in the Mahābhārata, see my paper “Nāsti daive prabhutvam. Traces of demythologisation in Indian Epic thought.” Journal of Indian Philosophy 26 (1998): 27-50.
[...]