tiling over the switch or receptical will work, BUT the problem, the toggle or receptilcle will be too far behind the front plate to reach it.
This is what I would do.
remove the switch plate, remove the toggle and or recepticle from the box. Flip the breaker to that area if you are not sure of your process. But if your careful, you do not have to, esp if it darkens the work area.
Do not unhook any wiring, just pull out the switch/receptilce from the box. Only two screws to do this.
Now tile to the box and just over the side of the box, make sure the old screw holes are still accessible.
Now, you will have to get two new screws since the old ones will be too short. Get longer ones.
After tiling and grouting, screw the recepticle/switch back where it was. Now screw the plate back on and its just like new again.
When I do tiling around switch/recepticles, I end up getting oversized plates to install because they hide any tile work that may not be straight. They are called oversized plates.
Believe me, this will look better, no gaps, no extreme recesses, no short toggles, and it works.