diff options
| author | Sergey Maranchuk <slav0nic@python.su> | 2020-04-17 22:12:06 +0300 |
|---|---|---|
| committer | Sergey Maranchuk <slav0nic@python.su> | 2020-04-17 22:12:06 +0300 |
| commit | 6668e43d2d67db4574e08a9d54bd80eb105c1b28 (patch) | |
| tree | 10eda61b15ae53815af24af956267e2f632a46f7 /tests/test_config/pkgs | |
| parent | 48cf45b0a1ac04e701101fa18778164825edd429 (diff) | |
| download | pyramid-6668e43d2d67db4574e08a9d54bd80eb105c1b28.tar.gz pyramid-6668e43d2d67db4574e08a9d54bd80eb105c1b28.tar.bz2 pyramid-6668e43d2d67db4574e08a9d54bd80eb105c1b28.zip | |
inheriting from `object` not necessary in py3
Diffstat (limited to 'tests/test_config/pkgs')
| -rw-r--r-- | tests/test_config/pkgs/scannable/__init__.py | 10 | ||||
| -rw-r--r-- | tests/test_config/pkgs/scannable/another.py | 6 |
2 files changed, 8 insertions, 8 deletions
diff --git a/tests/test_config/pkgs/scannable/__init__.py b/tests/test_config/pkgs/scannable/__init__.py index e0042a5cc..f0e730e15 100644 --- a/tests/test_config/pkgs/scannable/__init__.py +++ b/tests/test_config/pkgs/scannable/__init__.py @@ -18,7 +18,7 @@ def stacked(context, request): return 'stacked' -class stacked_class(object): +class stacked_class: def __init__(self, context, request): self.context = context self.request = request @@ -49,7 +49,7 @@ oldstyle_grokked_class = view_config( )(oldstyle_grokked_class) -class grokked_class(object): +class grokked_class: def __init__(self, context, request): self.context = context self.request = request @@ -63,7 +63,7 @@ grokked_class = view_config(name='grokked_class', renderer=null_renderer)( ) -class Foo(object): +class Foo: def __call__(self, context, request): return 'grokked_instance' @@ -74,7 +74,7 @@ grokked_instance = view_config( )(grokked_instance) -class Base(object): +class Base: @view_config(name='basemethod', renderer=null_renderer) def basemethod(self): """ """ @@ -109,7 +109,7 @@ def stuff(): """ """ -class Whatever(object): +class Whatever: pass diff --git a/tests/test_config/pkgs/scannable/another.py b/tests/test_config/pkgs/scannable/another.py index 31e7f5128..8a1c726a0 100644 --- a/tests/test_config/pkgs/scannable/another.py +++ b/tests/test_config/pkgs/scannable/another.py @@ -18,7 +18,7 @@ def stacked(context, request): return 'another_stacked' -class stacked_class(object): +class stacked_class: def __init__(self, context, request): self.context = context self.request = request @@ -49,7 +49,7 @@ oldstyle_grokked_class = view_config( )(oldstyle_grokked_class) -class grokked_class(object): +class grokked_class: def __init__(self, context, request): self.context = context self.request = request @@ -63,7 +63,7 @@ grokked_class = view_config( )(grokked_class) -class Foo(object): +class Foo: def __call__(self, context, request): return 'another_grokked_instance' |
