[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How are TAP programs initiated?

From: Nick Bowler
Subject: Re: How are TAP programs initiated?
Date: Fri, 29 May 2015 13:35:21 -0400
User-agent: Mutt/1.5.23 (2014-03-12)

On 2015-05-29 08:24 -0700, Arthur Schwarz wrote:
> I've looked through and Makefile and I have missed how a
> test script is executed and information passed to I do
> know that the program passed to seems to be ignored.

How do you know that?  The program name is clearly not ignored;
in fact it is mandatory.

> The ${AWK} program then reads from a 'getline' which I guess reads
> from a piped input.

Probably, but you don't have to guess.  The awk language is
defined in the POSIX standard, and the GNU awk manual is excellent.
See ยง4.9 "Explicit Input with Getline"[1]

  4.9.1 Using getline with No Arguments

  The getline command can be used without arguments to read input from
  the current input file. All it does in this case is read the next
  input record and split it up into fields.

> but I can't find in Makefile where the script is executed. Is the
> stuff preceding tap-driver execution executing the test scipt?

I tried a quick test, and looked at the generated Makefile.  There is
only one command in my Makefile that executes tap-driver, and it looks
like this:

  $(am__check_pre) $(TAP_LOG_DRIVER) --test-name "$$f" \
  --log-file $$b.log --trs-file $$b.trs \
  $(am__common_driver_flags) $(AM_TAP_LOG_DRIVER_FLAGS) $(TAP_LOG_DRIVER_FLAGS) 

The program name and its arguments are everything after the "--".

> Is TAP processing:
>     ./script |      # or
> -- ./script     # passed as an argument

Neither usage is correct.  Did you try them?  I imagine you did not
because the first command causes to print its basic usage

  Usage: --test-name=NAME --log-file=PATH --trs-file=PATH
                  [--expect-failure={yes|no}] [--color-tests={yes|no}]
                  [--enable-hard-errors={yes|no}] [--ignore-exit]
                  [--diagnostic-string=STRING] [--merge|--no-merge]
                  [--comments|--no-comments] [--] TEST-COMMAND
  The `--test-name', `--log-file' and `--trs-file' options are mandatory.


Nick Bowler, Elliptic Technologies (

reply via email to

[Prev in Thread] Current Thread [Next in Thread]