I didn't say they don't do
drug tests. I said they don't do anti-doping control
These players (and so many others before them) have been banned for drug use (mainly cannabis).
Not steroids!
Those with legal background, will surely agree that the term "Illegal substances" is a very nice way to say that "it's up to me to select which substances are allowed and which are not".
And if you bother looking briefly into what kind of substances are listed as "illegal" in the NBA, you will be amazed to find that this list does not match the WADA one...