That’s an easy one. Simply
/cast Divine Shield
/cast Flash of Light
It won’t attempt to do both, it will do the first one, and if it can’t succeed, it will do the second. If you want it to show the shield’s cooldown and tooltip, start the macro with
#showtooltip