Skip to content

Commit fdb849f

Browse files
committed
Merge remote-tracking branch 'origin/parametrise_tests' into parametrise_tests2
2 parents af8652f + 03f1e02 commit fdb849f

File tree

3 files changed

+29
-15
lines changed

3 files changed

+29
-15
lines changed

examples/api.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ export async function authorizeAccount(
4343
const accountTransactions = authValue.transactions;
4444
const accountBytes = authValue.bytes;
4545

46-
if (accountTransactions > transactions && accountBytes > bytes) {
46+
if (accountTransactions >= transactions && accountBytes >= bytes) {
4747
console.log('✅ Account authorization is sufficient.');
4848
continue;
4949
}

examples/justfile

Lines changed: 27 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -628,18 +628,29 @@ run-authorize-preimage-and-store-papi runtime ws_url="ws://localhost:10000" seed
628628
exit $EXAMPLE_EXIT
629629

630630
# ============================================================================
631-
# Run tests against external environments
631+
# Live network tests (external endpoints - Westend, Paseo, etc.)
632632
# ============================================================================
633-
634-
# Run store-big-data test against an external endpoint
633+
#
634+
# Run store-big-data test against live Bulletin chain deployments.
635+
# These require pre-authorized accounts and a local Docker Kubo connected to collators.
636+
#
637+
# Usage:
638+
# just run-live-tests-westend <seed>
639+
# just run-live-tests-paseo <seed>
640+
641+
# Live network endpoints
642+
WESTEND_RPC := "wss://westend-bulletin-rpc.polkadot.io"
643+
PASEO_RPC := "wss://paseo-bulletin-rpc.polkadot.io"
644+
645+
# Run store-big-data test against a live endpoint
635646
# Parameters:
636647
# ws_url - WebSocket URL of the Bulletin chain node
637-
# seed - Account seed phrase or dev seed (e.g., "//Alice" or "word1 word2 ...")
638-
# http_ipfs_api - IPFS API URL (default: http://127.0.0.1:5011 for local Docker Kubo)
639-
run-tests-against ws_url seed http_ipfs_api="http://127.0.0.1:5011": npm-install
648+
# seed - Account seed phrase (must be pre-authorized on the network)
649+
# http_ipfs_api - IPFS API URL (default: http://127.0.0.1:8283 for local Docker Kubo)
650+
_run-live-tests ws_url seed http_ipfs_api="http://127.0.0.1:8283": npm-install
640651
#!/usr/bin/env bash
641652
set -e
642-
echo "🌐 Testing against external endpoint: {{ ws_url }}"
653+
echo "🌐 Running live tests against: {{ ws_url }}"
643654
just papi-generate "{{ ws_url }}"
644655

645656
# To use local Docker Kubo with external RPC:
@@ -649,9 +660,12 @@ run-tests-against ws_url seed http_ipfs_api="http://127.0.0.1:5011": npm-install
649660

650661
node store_big_data.js "{{ ws_url }}" "{{ seed }}" "{{ http_ipfs_api }}"
651662

652-
# Run store-big-data test against Westend Bulletin
653-
# Parameters:
654-
# seed - Account seed phrase or dev seed (e.g., "//Alice" or "word1 word2 ...")
655-
# http_ipfs_api - IPFS API URL (default: http://127.0.0.1:5011 for local Docker Kubo)
656-
run-tests-against-westend seed http_ipfs_api="http://127.0.0.1:5011":
657-
just run-tests-against "wss://westend-bulletin-rpc.polkadot.io" "{{ seed }}" "{{ http_ipfs_api }}"
663+
# Run live tests against Westend Bulletin
664+
run-live-tests-westend seed http_ipfs_api="http://127.0.0.1:8283":
665+
just _run-live-tests "{{ WESTEND_RPC }}" "{{ seed }}" "{{ http_ipfs_api }}"
666+
667+
# Run live tests against Paseo Bulletin
668+
run-live-tests-paseo seed http_ipfs_api="http://127.0.0.1:8283":
669+
just _run-live-tests "{{ PASEO_RPC }}" "{{ seed }}" "{{ http_ipfs_api }}"
670+
671+
# TODO: missingn PoP

examples/store_big_data.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ const IPFS_GATEWAY_URL = args[2] || DEFAULT_IPFS_GATEWAY_URL;
3737
// Derive API URL from gateway URL (port 8283 -> 5011)
3838
const IPFS_API_URL = IPFS_GATEWAY_URL.replace(':8283', ':5011');
3939
// Image size preset: small, big32, big64, big96
40-
const IMAGE_SIZE = args[3] || 'big96';
40+
const IMAGE_SIZE = args[3] || 'big64';
4141
const NUM_SIGNERS = 16;
4242

4343
// -------------------- queue --------------------

0 commit comments

Comments
 (0)