In general I would agree with you, you oughta look at what a legislation does in practice. But here, because there is a sense of urgency (sending a gay refugee back to Somalia, for instance, is akin to signing their death warrant) and because the executive order hasn't been around for a while, I think it's ok to refer to what the administration intended the order to do. Because we don't have a lot of field evidence. As we see concrete evidence for the effects of a legislation, I think you're right and the weight of what it was theoretically intended should decrease pretty quickly (and it usually does).
The administration also didn't present to the court any sort of evidence supporting the claim that it would prevent terrorism.