EK like many other carriers codeshare with carriers..regardless if they are in an alliance or not.
I flew a few months ago and got UA miles. A number of years ago, when EK started JFK-DXB, I was able to get BA miles..
Of the "Big-3" (EY, QR and EK), I see QR joining an alliance.
I think OneWorld should get GF into the mix. It would help both GF and OneWorld.