def test_prop_wrong_order(self):
    with self.assertRaisesRegexp(ValueError, 'make sure @property appears before @deprecated in your source code'):

        class _Object(object):

            def __init(self):
                pass

            @deprecation.deprecated('2016-07-04', 'Instructions.')
            @property
            def _prop(self):
                return 'prop_wrong_order'
def test_prop_wrong_order(self):
    with self.assertRaisesRegexp(ValueError, 'make sure @property appears before @deprecated in your source code'):

        class _Object(object):

            def __init(self):
                pass

            @deprecation.deprecated('2016-07-04', 'Instructions.')
            @property
            def _prop(self):
                return 'prop_wrong_order'