per page, with , order by , clip by
Results of 1 - 2 of about 2 for TestFuncAcceptsSequencesMixin (0.003 sec.)
test --- Regression tests package for Python — Python 3.14.8 ドキュメント 11228
ナビゲーション 索引 モジュール | 次へ | 前へ | Python » 3.14.8 Documentation » The Python standard library » 開発ツール » test --- Regression tests package for Python テーマ 自動 ライト ダーク | test --- Regression tests package for Python ... さくすることができます。例えば以下のように、サブクラスで入力を指定することで、コードの重複を最小化することができます: class TestFuncAcceptsSequencesMixin : func = mySuperWhammyFunction def test_func ( self ): self . func ( self . arg ) class AcceptLists ( TestFuncAcceptsSeque ... ncesMixin , unittest . TestCase ): arg = [ 1 , 2 , 3 ] class AcceptStrings ( TestFuncAcceptsSequencesMixin , unittest . TestCase ): arg = 'abc' class AcceptTuples ( TestFuncAcceptsSequencesMixin , unittest . TestCase ): arg = ( 1 ... , 2 , 3 ) When using this pattern, remember that all classes that inherit from unittest.TestCase are run as tests. The TestFuncAcceptsSequencesMixin class in the example above does not have any data and so can't be run by itself, thus it does not inherit from unittest.Te ...
https://man.mtool.work/python/3.14/library/test.html
test --- Regression tests package for Python — Python 3.14.8 ドキュメント 7485
ナビゲーション 索引 モジュール | 次へ | 前へ | Python » 3.14.8 Documentation » The Python standard library » 開発ツール » test --- Regression tests package for Python テーマ 自動 ライト ダーク | test --- Regression tests package for Python ... さくすることができます。例えば以下のように、サブクラスで入力を指定することで、コードの重複を最小化することができます: class TestFuncAcceptsSequencesMixin : func = mySuperWhammyFunction def test_func ( self ): self . func ( self . arg ) class AcceptLists ( TestFuncAcceptsSeque ... ncesMixin , unittest . TestCase ): arg = [ 1 , 2 , 3 ] class AcceptStrings ( TestFuncAcceptsSequencesMixin , unittest . TestCase ): arg = 'abc' class AcceptTuples ( TestFuncAcceptsSequencesMixin , unittest . TestCase ): arg = ( 1 ... , 2 , 3 ) When using this pattern, remember that all classes that inherit from unittest.TestCase are run as tests. The TestFuncAcceptsSequencesMixin class in the example above does not have any data and so can't be run by itself, thus it does not inherit from unittest.Te ...
https://man.mtool.work/python/3.14/library/test.html
PREV 1 NEXT