#!/usr/bin/env bash
process_keys() {
  cat keysA_rank0000_in.log keysA_rank0001_in.log keysA_rank0002_in.log keysA_rank0003_in.log | sort -n -k 5  > keysA_in.log
  cat keysA_rank0000_out.log keysA_rank0001_out.log keysA_rank0002_out.log keysA_rank0003_out.log | sort -n -k 5 > keysA_out.log

  cat keysC_rank0000_in.log keysC_rank0001_in.log keysC_rank0002_in.log keysC_rank0003_in.log | sort -n -k 5  > keysC_in.log
  cat keysC_rank0000_out.log keysC_rank0001_out.log keysC_rank0002_out.log keysC_rank0003_out.log | sort -n -k 5 > keysC_out.log
}
. ./test_serial.sh
test_serial keyval_1 post_hook:process_keys \
  diff:keysC_in.log keysC_out.log \
  diff:keysA_in.log keysA_out.log
