Don't try swapping wires and connecting to the driver, you can blow drivers that way.

Basically you have 4 coils, 8 ends so you can measure continuity between two wires and that's one coil.

The stepper may be kaput if when all the leads are twisted together you can still turn the motor easily. I bought one off ebay that did this, sent it back.

.