From cd565d3784d62a77cfd31ebc67553f6a8feff1c7 Mon Sep 17 00:00:00 2001 From: xjd Date: Wed, 24 Jan 2024 10:56:50 +0800 Subject: [PATCH] Add test vectors --- README.md | 7 ------- test-vectors/README.md | 3 +++ test-vectors/run-all.sh | 6 ++++++ 3 files changed, 9 insertions(+), 7 deletions(-) create mode 100644 test-vectors/README.md create mode 100644 test-vectors/run-all.sh diff --git a/README.md b/README.md index ec6eeba..2bfae43 100644 --- a/README.md +++ b/README.md @@ -20,10 +20,3 @@ cd tests/omni_lock_rust && cargo test See [RFC](https://github.com/nervosnetwork/rfcs/blob/master/rfcs/0042-omnilock/0042-omnilock.md) - -## Test Vector - -```shell -# Project root directory -ckb-debugger --bin build/omni_lock -f test-vectors/tx_btc_P2PKH_compressed.json -i 0 -s lock -``` diff --git a/test-vectors/README.md b/test-vectors/README.md new file mode 100644 index 0000000..582d494 --- /dev/null +++ b/test-vectors/README.md @@ -0,0 +1,3 @@ + +These test vectors require [ckb-debugger](https://github.com/nervosnetwork/ckb-standalone-debugger.git) installed. +Use shell script `run-all.sh` to run all scripts. diff --git a/test-vectors/run-all.sh b/test-vectors/run-all.sh new file mode 100644 index 0000000..51e4f1a --- /dev/null +++ b/test-vectors/run-all.sh @@ -0,0 +1,6 @@ +#!/bin/bash + +for file in *.json; do + ckb-debugger --bin ../build/omni_lock -f $file -i 0 -s lock +done +