While the appreciative audience for bad puns on Oscar Wilde play titles may be limited, it is important to know if somebody is being serious or not in German, especially when your goal is to achieve a proficient level of communication in that language.
If Johanna and Julia both have husbands named Ernst, and somebody announces to them that a man named Ernst is on the telephone, Johanna might ask Julia Das ist nicht dein Ernst, oder? to see if Julia's husband is calling or if it's her own husband on the telephone. In all other cases, however, a reference to the noun der Ernst ("seriousness") preceded by a possessive pronoun (mein, dein, Ihr, euer, unser) means something else altogether:
Das is'... das ist nicht dein Ernst, oder?
That is... you're not serious, right?Play Caption
The phrase would translate literally (and rather clumsily) as "Is that not your seriousness?," but what is meant is "You're not serious?"
Here's another example of the phrase, this time with the second person plural possessive pronoun:
Des isch net euern Ernscht [Dialekt, das ist nicht euer Ernst].
You can't be serious.
Caption 71, Die Pierre-M.-Krause-Show - Classics - Part 3Play Caption
Another way of stating whether somebody is being serious or not is to use the noun der Ernst preceded by the dative preposition in:
Das meinst du nicht im Ernst.
You can't be serious.Play Caption
Im Ernst is in fact the most common way to say "seriously":
Nein! -Ja, ganz im Ernst.
No! -Yes, seriously.Play Caption
If you are taking your German lessons seriously, you can go to Yabla German and find other uses of der Ernst in a real-world context — excepting, of course, the rare occasion when Johanna or Julia's husband Ernst shows up!