Identifying windings of a single phase induction motor
Tricky solution:

Measure the winding resistances. Auxiliary windings are often thinner and therefore have a higher resistance (even if it's just a little bit higher).

Once you know which terminals are used for each of the two windings, you
can connect them to the power supply and the capacitor as shown in the following picture:



The picture was taken from the book "R. Fischer: Elektrische Maschinen, 15.Auflage, Hanser Verlag München"

Cleaner solution

Apply a (small) DC voltage step to a test circuit, consisting of a resistor and one of the windings in serial combination. Capture the current with an oscilloscope. Measure the time constant of the system and calculate the inductance L of the winding. Repeat this process for the second winding. The winding with the higher inductance value should be the main winding.