autobahn.xbr.test.test_xbr_secmod


Module Contents

Classes

TestSecurityModule

A unit test. The atom of the unit testing universe.

Attributes

HAS_INFURA

IS_CPY_310

autobahn.xbr.test.test_xbr_secmod.HAS_INFURA
autobahn.xbr.test.test_xbr_secmod.IS_CPY_310
class autobahn.xbr.test.test_xbr_secmod.TestSecurityModule(methodName='runTest')[source]

Bases: twisted.trial.unittest.TestCase

A unit test. The atom of the unit testing universe.

This class extends L{SynchronousTestCase} which extends C{unittest.TestCase} from the standard library. The main feature is the ability to return C{Deferred}s from tests and fixture methods and to have the suite wait for those C{Deferred}s to fire. Also provides new assertions such as L{assertFailure}.

@ivar timeout: A real number of seconds. If set, the test will raise an error if it takes longer than C{timeout} seconds. If not set, util.DEFAULT_TIMEOUT_DURATION is used.

setUp()[source]

Hook method for setting up the test fixture before exercising it.

test_ethereum_key_from_seedphrase()[source]

Create key from seedphrase and index.

test_ethereum_key_from_bytes()[source]

Create key from raw bytes.

test_ethereum_sign_typed_data_pesu_manual()[source]

Test using py_eth_sig_utils by doing individual steps / manually.

test_ethereum_sign_typed_data_pesu_highlevel()[source]

Test using py_eth_sig_utils with high level functions.

test_ethereum_sign_typed_data_ab_async()[source]

Test using autobahn with async functions.

test_ethereum_verify_typed_data_pesu_manual()[source]

Test using py_eth_sig_utils by doing individual steps / manually.

test_ethereum_verify_typed_data_pesu_highlevel()[source]

Test using py_eth_sig_utils with high level functions.

test_ethereum_verify_typed_data_ab_async()[source]

Test using autobahn with async functions.

test_secmod_iterable()[source]

This tests:

  • SecurityModuleMemory.from_seedphrase()

  • SecurityModuleMemory.__len__()

  • SecurityModuleMemory.__iter__()

  • SecurityModuleMemory.__getitem__()

test_secmod_create_key()[source]

This tests:

  • SecurityModuleMemory.create_key()

test_secmod_delete_key()[source]

This tests:

  • SecurityModuleMemory.create_key()

  • SecurityModuleMemory.delete_key()

test_secmod_counters()[source]

This tests:

  • SecurityModuleMemory.__init__()

  • SecurityModuleMemory.get_counter()

  • SecurityModuleMemory.increment_counter()

test_cryptosign_key_from_seedphrase()[source]
test_secmod_from_seedphrase()[source]
test_secmod_from_config()[source]
test_secmod_from_keyfile()[source]