I tested the bulb (while it was in the socket) by touching the side of the bulb (-ve) (not the socket itself so that I knew that there was some contact) and the wire inside the socket (+ve) and there was power. Should I do it differently ?

I'll check the pins out Patch.

What confuses me is that it flashes when my foot comes off the brake and not on when I would've expected.