#! /usr/bin/env bash
#
# A finalizer to diff the output generated by one of the other btest-rst-*
# commands. This does nothing if we're running from inside Sphinx.

# btest-rst-cmd generates these files if run from inside btest (but not Sphinx).

if [ "$BTEST_RST_OUTPUT" != "" ]; then
    exit 0
fi

for output in `find btest-${TEST_NAME}*`; do
    echo `pwd`/$output
    btest-diff $output
done
