<commit_before>#!/usr/bin/env bash

. $(dirname ${0})/common.sh
[[ -f ${_RESTAFARI_HOME}/env.sh ]] && . ${_RESTAFARI_HOME}/env.sh

cd ${_RESTAFARI_HOME}

# Test role processing

for f in $(ls ${_RESTAFARI_HOME}/test/rests/pass/*.rest); do
  # coverage3 run
  $SUCCESS "Running $f" ${RESTAFARI_CMD} --port ${TEST_SERVER_PORT} --hostname localhost $f
  [[ ${?} -gt 0 ]] && echo "Test failed!" && exit 1
done
echo "Test DONE"
<commit_msg>Add the command output tests<commit_after>#!/usr/bin/env bash

. $(dirname ${0})/common.sh
[[ -f ${_RESTAFARI_HOME}/env.sh ]] && . ${_RESTAFARI_HOME}/env.sh

cd ${_RESTAFARI_HOME}

# Test role processing
for f in $(ls ${_RESTAFARI_HOME}/test/rests/pass/*.rest); do
  # coverage3 run
  $SUCCESS "Running $f" ${RESTAFARI_CMD} --port ${TEST_SERVER_PORT} --hostname localhost $f
  [[ ${?} -gt 0 ]] && echo "Test failed!" && exit 1
done

# Test potential exeception failure
for f in $(ls ${_RESTAFARI_HOME}/test/exceptions_test/*/run.sh); do
  $SUCCESS "Running $f" bash ${f}
  [[ ${?} -gt 0 ]] && echo "Test failed!" && exit 1
done

echo "Test DONE"

{'fraction_non_alphanumeric': 0.1933395004625347, 'fraction_numerical': 0.009250693802035153, 'mean_word_length': 4.07981220657277, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '699735', 'n_tokens_mistral': 445, 'n_tokens_neox': 422, 'n_words': 107}