Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Chore: Update testing to use current python SDK. #5861

Merged
merged 2 commits into from
Dec 8, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
7 changes: 4 additions & 3 deletions test/scripts/e2e.sh
Original file line number Diff line number Diff line change
Expand Up @@ -125,9 +125,10 @@ if [ -z "$E2E_TEST_FILTER" ] || [ "$E2E_TEST_FILTER" == "SCRIPTS" ]; then
. "${TEMPDIR}/ve/bin/activate"
"${TEMPDIR}/ve/bin/pip3" install --upgrade pip

# Pin a version of our python SDK's so that breaking changes don't spuriously break our tests.
# Please update as necessary.
"${TEMPDIR}/ve/bin/pip3" install py-algorand-sdk==1.17.0
# Pin major version of our python SDK's so that breaking changes
# don't spuriously break our tests. If a minor version breaks our
# tests, we ought to find out.
"${TEMPDIR}/ve/bin/pip3" install 'py-algorand-sdk==2.*'

# Enable remote debugging:
"${TEMPDIR}/ve/bin/pip3" install --upgrade debugpy
Expand Down
5 changes: 3 additions & 2 deletions test/scripts/e2e_client_runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -114,11 +114,12 @@ def _script_thread_inner(runset, scriptname, timeout):
params = algod.suggested_params()
round = params.first
max_init_wait_rounds = 5
txn = algosdk.transaction.PaymentTxn(sender=maxpubaddr, fee=params.min_fee, first=round, last=round+max_init_wait_rounds, gh=params.gh, receiver=addr, amt=1000000000000, flat_fee=True)
params.last = params.first + max_init_wait_rounds
txn = algosdk.transaction.PaymentTxn(maxpubaddr, params, addr, 1_000_000_000_000)
stxn = kmd.sign_transaction(pubw, '', txn)
txid = algod.send_transaction(stxn)
ptxinfo = None
for i in range(max_init_wait_rounds):
for _ in range(max_init_wait_rounds):
txinfo = algod.pending_transaction_info(txid)
if txinfo.get('round'):
break
Expand Down
2 changes: 1 addition & 1 deletion test/scripts/e2e_subs/example.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
import sys
from goal import Goal

import algosdk.future.transaction as txn
import algosdk.transaction as txn
from datetime import datetime

stamp = datetime.now().strftime("%Y%m%d_%H%M%S")
Expand Down
2 changes: 1 addition & 1 deletion test/scripts/e2e_subs/goal/goal.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import subprocess

import algosdk
import algosdk.future.transaction as txn
import algosdk.transaction as txn
import algosdk.encoding as enc


Expand Down
2 changes: 0 additions & 2 deletions test/scripts/e2e_subs/min_balance.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,6 @@
from pathlib import PurePath
import sys

import algosdk.future.transaction as txn

from goal import Goal

# Set INTERACTIVE True if you want to run a remote debugger interactively on the given PORT
Expand Down
2 changes: 1 addition & 1 deletion test/scripts/e2e_subs/shared-resources.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import os
import sys
import algosdk.encoding as enc
import algosdk.future.transaction as txn
import algosdk.transaction as txn
from goal import Goal

from datetime import datetime
Expand Down