Skip to content

Commit

Permalink
Fix a test.
Browse files Browse the repository at this point in the history
  • Loading branch information
John-LittleBearLabs committed Aug 25, 2023
1 parent ddb1afe commit 19fd8f0
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
12 changes: 6 additions & 6 deletions testing/local_test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ fi
( "${0}" die 2>/dev/null >/dev/null <&- & ) &
cd `dirname "${0}"`/..
o=`mktemp -d`

rm log
check_log() {
l=${2-.}
for i in {0..9}
Expand Down Expand Up @@ -151,7 +151,7 @@ controller() {
port=${1}
shift
set -x
timeout 9 cargo run --bin controller -- -l 127.0.0.1:${port} "${@}" | tee log
timeout 9 cargo run --bin controller -- -l 127.0.0.1:${port} "${@}" 2>&1 | tee -a log
set +x
}
cid_present() {
Expand All @@ -165,7 +165,7 @@ cid_present() {
transmit() {
cid_present ${3} ${cid}
! cid_present ${4} ${cid}
timeout 9 cargo run --bin controller -- 127.0.0.1:${1} transmit-dag "${cid}" 127.0.0.1:${2} 9 | tee log
timeout 9 cargo run --bin controller -- 127.0.0.1:${1} transmit-dag "${cid}" 127.0.0.1:${2} 9 | tee -a log
for i in {0..9}
do
grep -n "${cid}" log */log || true
Expand All @@ -192,11 +192,11 @@ echo -e '\n# Test Case - Verify Myceli Instances Alive'

echo '1. Using controller software, send the `RequestAvailableBlocks` command to the `myceli` ground instance.'
controller 8765 request-available-blocks
echo '- This step passes if an `AvailableBlocks` response is received. Any other response / no response is a failure.'
echo '- This step passes if an `AvailableBlocks` response is received by ground. Any other response / no response is a failure.'
check_log 'Received.*AvailableBlocks'
echo '1. Using controller software, send the `RequestAvailableBlocks` command to the `myceli` space instance.'
echo '2. Using controller software, send the `RequestAvailableBlocks` command to the `myceli` space instance.'
controller 8764 request-available-blocks
echo '- This step passes if an `AvailableBlocks` response is received. Any other response / no response is a failure.'
echo '- This step passes if an `AvailableBlocks` response is received by space. Any other response / no response is a failure.'
check_log 'Received.*AvailableBlocks'

echo -e '\n# Test Case - Transmit an IPFS File (Ground to Space)'
Expand Down
2 changes: 1 addition & 1 deletion transports/src/udp_chunking.rs
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,7 @@ mod tests {
for size in data_sizes {
let chunk = SimpleChunk {
message_id: size,
sequence_number: size,
sequence_number: size.into(),
final_chunk: true,
data: vec![80; usize::from(size)],
};
Expand Down

0 comments on commit 19fd8f0

Please sign in to comment.