I was riding and noticed that I wasn't getting to the two or three smallest gears. Shifting along the eight or nine largest gears were fine though.
I checked the limiters and the cable tension and that was fine. After a lot of adjustment, I still couldn't get the full range. I then realized that I was only getting 9 clicks out of the shifter when instead I was expecting 10 clicks. Additionally, the first click (from no tension) didn't add any tension to the cable at all. I tried this with the cable off the derailleur and using a pair of pliers to manually pull on the cable.
You’ve taken the derailleur out of the system and still see the problem, next thing I would do is replace the cable. They have a bad habit of getting chewed up by the shifter and misbehaving, but you can’t see the damage. Very rusty cables give issues too but you’re unlikely to have a low quality cable, and would be able to see the poor condition.
Give it a try and update the question if there’s no improvement... which would only leave the shifter as a culprit.
My interpretation of "wasn't getting to the two or three smallest gears" is that the shifter is not paying out cable so the derailleur does not index onto the two smallest (11 and 12 tooth) sprockets.
The shifter relies on cable tension provided by the derailleur to pull cable out, so it could be that the cable is hanging up somewhere. Try pulling hard on the cable end while running the shifter and see if the shifter will function through all 10 up and downshifts. If it functions properly you know that the shifter is working at least.
Next step is to pull the cable and see if you can find where the hangup is. As Swifty mentioned that is likely in the shifter itself.