コード例 #1
0
ファイル: unit_tests.py プロジェクト: davidsoloman/pybitcoin
    def setUp(self):
        self.recipient_address = "1EEwLZVZMc2EhMf3LXDARbp4mA3qAwhBxu"
        self.private_key = BitcoinPrivateKey(BITCOIN_PRIVATE_KEY)
        self.send_amount = 1000

        self.blockcypher_client = blockcypher.BlockcypherClient(BLOCKCYPHER_API_KEY)
        self.chain_com_client = chain_com.ChainComClient(CHAIN_API_ID, CHAIN_API_SECRET)
        self.blockchain_info_client = blockchain_info.BlockchainInfoClient(BLOCKCHAIN_API_KEY)
        self.bitcoind_client = bitcoind_client
        self.bitcoind = create_bitcoind_service_proxy(BITCOIND_RPC_USERNAME, BITCOIND_RPC_PASSWORD)

        self.signed_tx = make_send_to_address_tx(
            self.recipient_address, self.send_amount, self.private_key, self.blockcypher_client
        )
コード例 #2
0
    def setUp(self):
        self.recipient_address = '1EEwLZVZMc2EhMf3LXDARbp4mA3qAwhBxu'
        self.private_key = BitcoinPrivateKey(BITCOIN_PRIVATE_KEY)
        self.send_amount = 1000

        self.blockcypher_client = blockcypher.BlockcypherClient(
            BLOCKCYPHER_API_KEY)
        self.blockchain_info_client = blockchain_info.BlockchainInfoClient(
            BLOCKCHAIN_API_KEY)
        self.bitcoind_client = bitcoind_client
        self.bitcoind = create_bitcoind_service_proxy(
            BITCOIND_RPC_USERNAME, BITCOIND_RPC_PASSWORD)

        self.signed_tx = make_send_to_address_tx(
            self.recipient_address, self.send_amount,
            self.private_key, self.blockcypher_client)
コード例 #3
0
ファイル: unit_tests.py プロジェクト: monorisk/pybitcoin
    def setUp(self):
        self.recipient_address = '1EEwLZVZMc2EhMf3LXDARbp4mA3qAwhBxu'
        self.private_key = BitcoinPrivateKey(SECRETS["private_key"])
        self.send_amount = 1000

        self.blockcypher_client = blockcypher.BlockcypherClient(
            SECRETS['blockcypher_api_key'])
        self.chain_com_client = chain_com.ChainComClient(
            SECRETS['chain_api_id'], SECRETS['chain_api_secret'])
        self.blockchain_info_client = blockchain_info.BlockchainInfoClient(
            SECRETS['blockchain_api_key'])
        self.bitcoind_client = bitcoind_client
        self.bitcoind = create_bitcoind_service_proxy(
            SECRETS['rpc_username'], SECRETS['rpc_password'])

        self.signed_tx = make_send_to_address_tx(
            self.recipient_address, self.send_amount,
            self.private_key, self.blockcypher_client)
コード例 #4
0
ファイル: unit_tests.py プロジェクト: monorisk/pybitcoin
 def test_namecoin_build_transaction(self):
     signed_tx = make_send_to_address_tx(self.recipient_address, 1000000,
         self.private_key, self.namecoind_client)
     resp = broadcast_transaction(signed_tx, self.namecoind_client)
     self.assertTrue(resp.get('success'))