diff --git a/.github/workflows/e2e-subtensor-tests.yaml b/.github/workflows/e2e-subtensor-tests.yaml index d56e9a726d..e88eb588f2 100644 --- a/.github/workflows/e2e-subtensor-tests.yaml +++ b/.github/workflows/e2e-subtensor-tests.yaml @@ -32,6 +32,9 @@ jobs: steps: - name: Check-out repository under $GITHUB_WORKSPACE uses: actions/checkout@v4 + with: + fetch-depth: 0 + ref: ${{ github.event.pull_request.head.sha }} - name: Set up Python uses: actions/setup-python@v5 @@ -147,6 +150,9 @@ jobs: steps: - name: Check-out repository uses: actions/checkout@v4 + with: + fetch-depth: 0 + ref: ${{ github.event.pull_request.head.sha }} - name: Set up Python ${{ matrix.python-version }} uses: actions/setup-python@v5 diff --git a/tests/e2e_tests/test_delegate.py b/tests/e2e_tests/test_delegate.py index 949b1324be..f681197e49 100644 --- a/tests/e2e_tests/test_delegate.py +++ b/tests/e2e_tests/test_delegate.py @@ -342,7 +342,7 @@ def test_nominator_min_required_stake( wallet=dave_wallet, hotkey_ss58=bob_wallet.hotkey.ss58_address, netuid=alice_subnet_netuid, - amount=Balance.from_tao(1000), + amount=Balance.from_tao(10_000), wait_for_inclusion=True, wait_for_finalization=True, ) diff --git a/tests/e2e_tests/test_stake_fee.py b/tests/e2e_tests/test_stake_fee.py index 049ee3cbe7..b20440c651 100644 --- a/tests/e2e_tests/test_stake_fee.py +++ b/tests/e2e_tests/test_stake_fee.py @@ -19,7 +19,7 @@ async def test_stake_fee_api(local_chain, subtensor, alice_wallet, bob_wallet): netuid = 2 root_netuid = 0 stake_amount = Balance.from_tao(100) # 100 TAO - min_stake_fee = Balance.from_tao(0.050354772) + min_stake_fee = Balance.from_tao(0.299076829) # Register subnet as Alice assert subtensor.register_subnet(alice_wallet), "Unable to register the subnet" @@ -32,9 +32,9 @@ async def test_stake_fee_api(local_chain, subtensor, alice_wallet, bob_wallet): coldkey_ss58=alice_wallet.coldkeypub.ss58_address, hotkey_ss58=alice_wallet.hotkey.ss58_address, ) - assert isinstance(stake_fee_0, Balance), "Stake fee should be a Balance object." + assert isinstance(stake_fee_0, Balance), "Stake fee should be a Balance object" assert stake_fee_0 == min_stake_fee, ( - "Stake fee should be equal the minimum stake fee." + "Stake fee should be equal the minimum stake fee" ) # Test unstake fee @@ -44,11 +44,9 @@ async def test_stake_fee_api(local_chain, subtensor, alice_wallet, bob_wallet): coldkey_ss58=alice_wallet.coldkeypub.ss58_address, hotkey_ss58=bob_wallet.hotkey.ss58_address, ) - assert isinstance(unstake_fee_root, Balance), ( - "Stake fee should be a Balance object." - ) - assert unstake_fee_root == min_stake_fee, ( - "Root unstake fee should be equal the minimum stake fee." + assert isinstance(unstake_fee_root, Balance), "Stake fee should be a Balance object" + assert unstake_fee_root == Balance.from_rao(299076829), ( + "Root unstake fee should be 0." ) # Test various stake movement scenarios