A socket tester is a small, handheld device that is plugged into a socket to quickly confirm if an AC wall socket is working
The circuit resembles this socket tester:
https://nl.farnell.com/productimages/large/en_GB/IN09325-40.jpg
When turning on the 3 SPST switches, the green LEDs (L-N and L-PE) will emit light.
When reversing L and N (upper left and upper middle SPDT switches) green LEDs (L-N) will keep on emitting light as well as the red LEDs (N-PE).
When reversing L and PE (lower left and upper right SPDT switches) green LEDs (L-PE) will keep on emitting light as well as the red LEDs (N-PE).
When turning off the N SPST switch, green LEDs (L-PE) will keep on emitting light, the other LEDs will emit a little bit of light.
When turning off the PE SPST switch, green LEDs (L-N) will keep on emitting light, the other LEDs will emit a little bit of light.
Some socket testers have more functions like RCD testing and check if N-PE are reversed (basically a RCD test switch testing the N pole).