File: msg_parse_001.sh

package info (click to toggle)
cod-tools 2.3%2Bdfsg-3
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 114,852 kB
  • sloc: perl: 53,336; sh: 23,842; ansic: 6,318; xml: 1,982; yacc: 1,112; makefile: 716; python: 158; sql: 73
file content (15 lines) | stat: -rwxr-xr-x 528 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
#!/bin/sh
##
# Tests the way error messages are formed when using COD::UserMessage
# module in command-line perl as well as reading from SDTIN as input file.
##

#BEGIN DEPEND------------------------------------------------------------------
INPUT_MODULE='src/lib/perl5/COD/UserMessage.pm'
#END DEPEND--------------------------------------------------------------------

echo "test error" | \
perl -e 'use COD::UserMessage qw( error );' \
     -e 'while (<>) {' \
     -e '    error($0, $ARGV, undef, $_, undef )' \
     -e '}'