"Fossies" - the Fresh Open Source Software Archive

Member "detox-1.4.5/tests/tests/github-issue-0014/test.sh" (15 Aug 2021, 749 Bytes) of package /linux/privat/detox-1.4.5.tar.gz:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) Bash source code syntax highlighting (style: standard) with prefixed line numbers and code folding option. Alternatively you can here view or download the uninterpreted source code file. See also the last Fossies "Diffs" side-by-side code changes report for "test.sh": 1.4.2_vs_1.4.3.

    1 #!/usr/bin/env bash
    2 #
    3 # Tests to confirm GitHub issue #14 is resolved
    4 #
    5 # https://github.com/dharple/detox/issues/14
    6 #
    7 
    8 set -e
    9 
   10 if [ -z "$TESTBASE" ] ; then
   11     echo TESTBASE needs to be passed via the env
   12     exit 1
   13 fi
   14 
   15 . $TESTBASE/test-functions
   16 
   17 # Run the test based on data from
   18 # https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=861537
   19 
   20 DETOX=$1
   21 INPUT="mÉ Æ.txt"
   22 OUTPUT="mÉ_Æ.txt"
   23 METHOD="utf_8"
   24 TABLE="test.tbl"
   25 
   26 test_single_table "$DETOX" "$INPUT" "$OUTPUT" "$METHOD" "$TABLE"
   27 
   28 # ---------------------------------------------------------------------------
   29 
   30 # Run the same test, based on the default table
   31 
   32 OUTPUT="mE_AE.txt"
   33 TABLE=$(dirname $TESTBASE)/table/unicode.tbl.sample
   34 
   35 test_single_table "$DETOX" "$INPUT" "$OUTPUT" "$METHOD" "$TABLE"