mirror of
https://github.com/django/django.git
synced 2025-08-04 02:48:35 +00:00
Fixed #28869 -- Made tagged test classes and methods inherit tags from parents.
This commit is contained in:
parent
acd3baf2ae
commit
09530e61a0
6 changed files with 66 additions and 1 deletions
29
tests/test_runner_apps/tagged/tests_inheritance.py
Normal file
29
tests/test_runner_apps/tagged/tests_inheritance.py
Normal file
|
@ -0,0 +1,29 @@
|
|||
from unittest import TestCase
|
||||
|
||||
from django.test import tag
|
||||
|
||||
|
||||
@tag('foo')
|
||||
class FooBase(TestCase):
|
||||
pass
|
||||
|
||||
|
||||
class Foo(FooBase):
|
||||
|
||||
def test_no_new_tags(self):
|
||||
pass
|
||||
|
||||
@tag('baz')
|
||||
def test_new_func_tag(self):
|
||||
pass
|
||||
|
||||
|
||||
@tag('bar')
|
||||
class FooBar(FooBase):
|
||||
|
||||
def test_new_class_tag_only(self):
|
||||
pass
|
||||
|
||||
@tag('baz')
|
||||
def test_new_class_and_func_tags(self):
|
||||
pass
|
Loading…
Add table
Add a link
Reference in a new issue