What colours correspond to what in Earphones?
simulate this circuit &ndash; Schematic created using CircuitLab

If you have identified two non-connected pairs the hook them up as shown. Play some music and have a listen. If they are out of phase you will get an odd "hole-in-your-head" sensation. Swap the wiring on one of the ear-pieces and try again. Normal stereo panorama should result.

Alternatively, if you can actually see the diaphragms on the earphones then you could apply a low voltage - maybe 1.5 V and see which way the diaphragm moves. Wire both in-phase.