Page MenuHomePhabricator

Merge #12856: Tests: Add Metaclass for BitcoinTestFramework
ClosedPublic

Authored by jasonbcox on Jun 3 2020, 21:26.

Details

Summary

c9cce0a Tests: Add Metaclass for BitcoinTestFramework (Will Ayd)

Pull request description:

BitcoinTestFramework instructs developers in its docstring to override
`set_test_params` and `run_test` in subclasses while being sure NOT to
override `__init__` and `main` . This change adds a metaclass to ensure
that developers adhere to that protocol, raising a ``TypeError`` in
instances where they have not.

closes #12835

Tree-SHA512: 5a47a7ead1f18361138cad4374747c4a8f29d25506f7b2c2a8c1c966a0b65e5ccf7317f9a078df8680fdab5d3fb71fee46a159c9f381878a3683c1e9f874abbe

Backport of Core PR12856

Test Plan

ninja check-functional

Diff Detail

Repository
rABC Bitcoin ABC
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

[Bot Message]
One or more PR numbers were detected in the summary.
Links to those PRs have been inserted into the summary for reference.

This revision is now accepted and ready to land.Jun 4 2020, 00:05