'When L{deprecatedProperty} is used on a C{property}, setter accesses
raise a L{DeprecationWarning}.'

def test_propertySetter(self):

    newValue = object()
    obj = ClassWithDeprecatedProperty()
    obj.someProperty = newValue
    self.assertIs(newValue, obj._someProtectedValue)
    message = 'twisted.python.test.test_deprecate.ClassWithDeprecatedProperty.someProperty    was    deprecated    in    Twisted    1.2.3'
    warnings = self.flushWarnings([self.test_propertySetter])
    self.assertEqual(1, len(warnings))
    self.assertEqual(DeprecationWarning, warnings[0]['category'])
    self.assertEqual(message, warnings[0]['message'])
