diff options
| author | Steve Piercy <web@stevepiercy.com> | 2016-07-03 17:16:55 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2016-07-03 17:16:55 -0700 |
| commit | e16832d028daf94642df7739f78b4f58d8c306c8 (patch) | |
| tree | d953c458d7193ae7edf17d28547080d4b805a680 | |
| parent | 384d78a75237ccb98fc7e01e2998a723d03dd455 (diff) | |
| parent | 2612de2f38094f3c04ebf991f1ca84b02bf5ae3f (diff) | |
| download | pyramid-e16832d028daf94642df7739f78b4f58d8c306c8.tar.gz pyramid-e16832d028daf94642df7739f78b4f58d8c306c8.tar.bz2 pyramid-e16832d028daf94642df7739f78b4f58d8c306c8.zip | |
Merge pull request #2671 from stevepiercy/master
Show testsetup code in rendered docs.
| -rw-r--r-- | pyramid/decorator.py | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/pyramid/decorator.py b/pyramid/decorator.py index ea518bfcb..e3a8c707f 100644 --- a/pyramid/decorator.py +++ b/pyramid/decorator.py @@ -8,6 +8,16 @@ class reify(object): replacing the function it decorates with an instance variable. It is, in Python parlance, a non-data descriptor. An example: + .. code-block:: python + + from pyramid.decorator import reify + + class Foo(object): + @reify + def jammy(self): + print('jammy called') + return 1 + .. testsetup:: from pyramid.decorator import reify |
