Beispiel #1
0
    def test_get_tx(self):
        api = SolanaApi(self.ADDRESS)
        result = api.get_tx(
            '5v1yotDftqHWpgCqDuPoEMaLwyQiHaCiDZ3i2Srf31oKosDRJerk4PQpretG4HkQb'
            'WqRgfSFPLLdKi9NuyGLcqQH')

        assert result
Beispiel #2
0
    def test_get_balance(self):
        api = SolanaApi(self.ADDRESS)
        result = api.get_balance()

        assert len(result) == 3
        assert next(b for b in result if b['symbol'] == 'SOL')
        assert next(b for b in result if b['symbol'] == 'YFI')
        usdc_bal = next(b for b in result if b['symbol'] == 'USDT')
        assert usdc_bal['amount'] == 21.17783
Beispiel #3
0
    def test_get_txs_signatures(self):
        api = SolanaApi(self.ADDRESS)
        result = api.get_txs_signatures()

        assert len(result) == 22