Please don't get caught in the trap of giving him anything jusst to get him to eat, or of asking and giving him anything he wants for that reason either. Whether he's testing you, or whether he is genuinely upset about something or ill, he needs consistency and reliability from you, and calmness too. It's very difficult, I know, but so important. My ds went through several hunger strikes (though admittedly none as tough as yours). Sometimes the reason was fairly obvious, or became obvious later, and for some I have no idea why they happened. Whatever the cause of the strike, your ds will be picking up on your feelings about it, and may be making it more extreme because it gets a reaction out of you.
A 3yo often cannot say 'why' he does something, and being asked why can be upsetting to him IME. 'What bothers you about xxxx?' may be better than 'Why won't you xxxx?'
What I did when ds went on strike was to continue presenting meals and snacks at the usual times, but make sure they were things he would normally eat (just not all 'treats' and in tiny portions. I did give him full-strength juice rather than diluted, as I thought the flavour might be more appetising.
For such an extreme hunger strike I'd be inclined to go to the doctor, or to your HV if you prefer, just to make sure there's nothing physical causing it.
Poor you. Very distressing...but these things do pass, honest!