While this circuit may not be as efficient as an LED driver module or a switching solution the LM317 is cheap and readily available. [Afroman] also describes how the circuit works in detail ...
and in fact that’s what [Dave]’s first LED tester was, in essence. Set an LM317 circuit up to output 10mA, say, and you can safely test out about any LED. Read off the operating voltage ...