This comes up a lot, and there are several tests, so I'll try to collect them here.
Testing an OT:
First check DC resistance of each of the windings (ohms in the hundreds is good for the primary, single-digits for the secondary), and from primary to secondary (good is infinite).
To check for shorted turns, which you can't detect with DC resistance measurements if only one or a few turns are shorted, you can use the method published by RG Keen using a neon bulb and a battery. See:
https://www.premierguitar.com/the-super ... mer-tester
Impedance Ratio: You need a source of low-voltage AC, like a filament transformer or an AC power adapter that puts out an AC voltage, and a DVM.
Apply the AC signal across the secondary (highest impedance tap) and measure the AC voltage on the secondary where you are applying the voltage and then on primary's outer (plate) leads. Dividing primary VAC by secondary VAC gives turns ratio, which you then square to get the impedance ratio.
Multiply the impedance ratio by the marked impedance at the secondary tap where you are applying the voltage and you get primary impedance- sort-of. It won't be exact, but likely within 10%.
It's worth checking all the secondary taps to be sure that they are correctly identified. Look for the highest voltage to appear on the primary when the signal is applied to the lowest impedance tap on the secondary and the lowest primary voltage to appear when the highest impedance secondary tap is used. You can also measure each secondary tap to secondary common. Expect to see the highest voltage on the highest output impedance tap, and lowest on the lowest impedance tap.
If the OT is installed in an amp:
In this case you can use the amp's own filament voltage for an AC source and minimize the number of leads you have to disconnect by doing the following:
Drain the filter caps, remove the valves, and disconnect the OT's CT from the B+.
Insert a 1/4" plug into the speaker jack and set impedance to the highest value if there is a selector switch. If the amp has a NFB loop you could disconnect it too, but it probably won't make any difference for this testing since the impedance to ground through that path will be much higher than that of the secondary. At this point you can make DC resistance measurements since the primary and secondary are open-circuit (NFB loop notwithstanding).
Turn the amp on, but leave the standby switch off if there is one. You don't need the high voltage here. Connect the tip lead of the speaker output to either side of the filamant winding at any convenient point (being careful of high voltage that could be nearby) and measure the AC voltage across the primary and the secondary. Assuming the filament circuit has a grounded CT (either actual or artificial using 2x ~100R resistors), the voltage applied to the secondary will be half of the filament voltage.
Proceed as above to calculate the approximate impedance ratio.
Phase Test:
It's also possible to determine the phase relationship between the primary and the secondary leads, which in my opinion is always worth checking before wiring in a new transformer.
The AC signal is applied to the secondary as before using the highest impedance tap, but for this test connect the primary's center tap to the "hot" side of the secondary winding where the signal voltage is being applied.
Measure the voltage from each primary lead to the ground side of the secondary. One of these voltage measurements will be higher than the other, and that lead will be the in-phase side of the primary. In the typical guitar amp with a LTP inverter, this is the lead that is connected to the tube(s) driven by the inverting side of the PI, which is the one that gets its grid signal directly from the preamp.