“The measure of a man’s character is what he would do if he knew he never would be found out.” Baron Thomas Babington Macauley
What this quote means is the real person we, our character, are becomes apparent when we do things which we think no one will ever know. A person of high moral character would do the same things, regardless of being found out or not. A person of low moral character will do certain things, and act one way in public, but their true self, their true character will appear when they are in private, when they think what they are doing will not be found out. A person of low moral character would ask who is watching, before doing something.
The way to become a person of character is to act the same way in private as in public. Rather than asking who is watching, a person of character asks ‘is it right’.