'L{twisted.conch.insults.helper.CharacterAttribute.wantOne} emits
a deprecation warning when invoked.'

def test_wantOneDeprecated(self):

    helper._FormattingState().wantOne(bold=True)
    warningsShown = self.flushWarnings([self.test_wantOneDeprecated])
    self.assertEqual(len(warningsShown), 1)
    self.assertEqual(warningsShown[0]['category'], DeprecationWarning)
    if _PY3:
        deprecatedClass = 'twisted.conch.insults.helper._FormattingState.wantOne'
    else:
        deprecatedClass = 'twisted.conch.insults.helper.wantOne'
    self.assertEqual(warningsShown[0]['message'], ('%s    was    deprecated    in    Twisted    13.1.0' % deprecatedClass))
