コード例 #1
0
ファイル: test_runners.py プロジェクト: Dpk28/nephos
 def test_runner_crypto(self, mock_admin_msp, mock_channel_tx,
                        mock_genesis_block, mock_setup_nodes):
     runner_crypto(self.OPTS)
     mock_admin_msp.assert_has_calls([
         call(self.OPTS, "ord_MSP", verbose=False),
         call(self.OPTS, "peer_MSP", verbose=False),
     ])
     mock_genesis_block.assert_called_once_with(self.OPTS, verbose=False)
     mock_channel_tx.assert_called_once_with(self.OPTS, verbose=False)
     # Setup node MSPs
     mock_setup_nodes.assert_has_calls([
         call(self.OPTS, "orderer", verbose=False),
         call(self.OPTS, "peer", verbose=False),
     ])
コード例 #2
0
 def test_runner_crypto(
     self,
     mock_admin_msp,
     mock_channel_tx,
     mock_genesis_block,
     mock_setup_nodes,
     mock_get_msps,
 ):
     mock_get_msps.side_effect = [{"AlphaMSP", "BetaMSP"}]
     runner_crypto(self.OPTS)
     mock_get_msps.assert_called_once_with(opts=self.OPTS)
     mock_admin_msp.assert_has_calls(
         [call(self.OPTS, "AlphaMSP"),
          call(self.OPTS, "BetaMSP")],
         any_order=True)
     mock_genesis_block.assert_called_once_with(self.OPTS)
     mock_channel_tx.assert_called_once_with(self.OPTS)
     # Setup node MSPs
     mock_setup_nodes.assert_has_calls([call(self.OPTS)])
コード例 #3
0
def crypto(settings):
    opts = load_config(settings.settings_file)
    runner_crypto(opts, verbose=settings.verbose)
コード例 #4
0
ファイル: deploy.py プロジェクト: appbootup/nephos-1
def crypto(settings):
    opts = load_config(settings.settings_file)
    runner_crypto(opts)