Files
quickbook/test/quickbook-testing.jam
Daniel James 07ff92c619 Merge several changes to boostbook and quickbook.
Fixes #1399

Merged revisions 49231,49459,49988,50068,50084,50091,50109,50125,50142,50159,50163,50175,50193,50207,50210-50213,50215,50222,50246,50513 via svnmerge from 
https://svn.boost.org/svn/boost/trunk

........
  r49231 | danieljames | 2008-10-09 23:14:14 +0100 (Thu, 09 Oct 2008) | 4 lines
  
  Work around the problems with window newlines in position_iterator. (I'm
  about to fix them, but this will get quickbook working immediately).
........
  r49459 | eric_niebler | 2008-10-26 20:24:59 +0000 (Sun, 26 Oct 2008) | 1 line
  
  give data members with <purpose> in synopses the same treatment as functions and typedefs
........
  r49988 | danieljames | 2008-11-28 15:05:21 +0000 (Fri, 28 Nov 2008) | 1 line
  
  When processing template arguments, deal with the case when there's no content after the last space or there are more arguments than expected.
........
  r50068 | johnmaddock | 2008-12-02 13:13:57 +0000 (Tue, 02 Dec 2008) | 1 line
  
  Fix Jamfile by adding <preserve-test-targets>on to test requirements.
........
  r50084 | johnmaddock | 2008-12-03 09:42:52 +0000 (Wed, 03 Dec 2008) | 1 line
  
  Added quickbook-fail-test rule and two tests that make use of it: note that these currently fail.
........
  r50091 | danieljames | 2008-12-03 19:14:42 +0000 (Wed, 03 Dec 2008) | 2 lines
  
  Keep a count of errors in quickbook, and return an error code when appropriate.
........
  r50109 | johnmaddock | 2008-12-04 10:14:19 +0000 (Thu, 04 Dec 2008) | 1 line
  
  Added dependency to the test file.
........
  r50125 | djowel | 2008-12-05 02:13:59 +0000 (Fri, 05 Dec 2008) | 1 line
  
  updated to use "classic" spirit includes and namespace
........
  r50142 | danieljames | 2008-12-05 19:03:19 +0000 (Fri, 05 Dec 2008) | 1 line
  
  Defined BOOST_CYGWIN_PATH when building quickbook on cygwin.
........
  r50159 | danieljames | 2008-12-06 14:07:35 +0000 (Sat, 06 Dec 2008) | 1 line
  
  Copy boostbook.dtd into the correct position for the 1.1 uri. I'm not sure what should be done with the existing location.
........
  r50163 | danieljames | 2008-12-06 19:22:32 +0000 (Sat, 06 Dec 2008) | 1 line
  
  Revert my change to the quickbook jamfile, it isn't adequately tested.
........
  r50175 | danieljames | 2008-12-07 12:37:07 +0000 (Sun, 07 Dec 2008) | 1 line
  
  Fix processing of unmatched escape characters in code - and issue a warning for unexpected characters.
........
  r50193 | danieljames | 2008-12-08 16:17:13 +0000 (Mon, 08 Dec 2008) | 1 line
  
  Use new include paths for classic spirit in quickbook text_diff utility.
........
  r50207 | danieljames | 2008-12-08 21:51:56 +0000 (Mon, 08 Dec 2008) | 1 line
  
  Fail on a mismatched '' in the python and c++ syntax highlighters. And then ignore the rest of the code block to avoid further errors and warnings.
........
  r50210 | danieljames | 2008-12-08 23:14:23 +0000 (Mon, 08 Dec 2008) | 1 line
  
  Hard fail on quickbook post process errors.
........
  r50211 | danieljames | 2008-12-08 23:20:26 +0000 (Mon, 08 Dec 2008) | 1 line
  
  Since I accidently added a quickbook fail tests to the Jamfile in the last checkin, I might as well add them.
........
  r50212 | danieljames | 2008-12-08 23:35:08 +0000 (Mon, 08 Dec 2008) | 1 line
  
  Remove an unused variable in order to avoid a gcc warning.
........
  r50213 | danieljames | 2008-12-08 23:35:20 +0000 (Mon, 08 Dec 2008) | 1 line
  
  Run the docbook chunker quietly, unless boostbook.verbose is set.
........
  r50215 | danieljames | 2008-12-08 23:38:29 +0000 (Mon, 08 Dec 2008) | 1 line
  
  Put the markup strings in their own cpp file to avoid gcc warnings.
........
  r50222 | danieljames | 2008-12-09 13:52:07 +0000 (Tue, 09 Dec 2008) | 1 line
  
  Fix some xsl type errors.
........
  r50246 | speedsnail | 2008-12-12 15:06:44 +0000 (Fri, 12 Dec 2008) | 1 line
  
  Make doxygen command "\throw" work with boostbook.
........
  r50513 | danieljames | 2009-01-08 12:01:50 +0000 (Thu, 08 Jan 2009) | 1 line
  
  Support both windows and cygwin paths in cygwin quickbook.
........


[SVN r51281]
2009-02-17 00:01:03 +00:00

107 lines
3.0 KiB
Plaintext

#
# Copyright (c) 2005 João Abecasis
#
# Distributed under the Boost Software License, Version 1.0. (See
# accompanying file LICENSE_1_0.txt or copy at
# http://www.boost.org/LICENSE_1_0.txt)
#
import feature ;
import generators ;
import modules ;
import project ;
import targets ;
import testing ;
import toolset ;
import type ;
feature.feature quickbook-testing.quickbook-command : : free dependency ;
type.register QUICKBOOK_INPUT : quickbook ;
type.register QUICKBOOK_OUTPUT ;
generators.register-standard quickbook-testing.process-quickbook : QUICKBOOK_INPUT : QUICKBOOK_OUTPUT ;
################################################################################
exe line-compare-tool : src/text_diff.cpp ;
#
# quickbook-test - generates a test for quickbook itself. A quickbook-test is
# actually made up of two tests:
# $(target-name).boostbook :
# generate boostbook from $(input) or $(target-name).quickbook
#
# $(target-name):
# compare generated boostbook to $(reference-output) or
# $(input).gold or $(target-name).gold
#
rule quickbook-test ( target-name : input ? : reference-output ? : requirements * )
{
input ?= $(target-name).quickbook ;
reference-output ?= $(input:S=.gold) ;
local project = [ project.current ] ;
local t =
[ targets.create-typed-target QUICKBOOK_OUTPUT
: $(project)
: $(target-name).boostbook
: $(input)
: $(requirements)
<location-prefix>$(target-name).test
<quickbook-testing.quickbook-command>..//quickbook
]
[ targets.create-typed-target RUN
: $(project)
: $(target-name)
: .//line-compare-tool
: $(requirements)
<location-prefix>$(target-name).test
<testing.input-file>$(reference-output)
<testing.input-file>$(target-name).boostbook
<preserve-test-targets>on
]
;
modules.poke testing : .all-tests : \$\(all-tests\) $(t) ;
return $(t) ;
}
rule quickbook-fail-test ( target-name : input ? : requirements * )
{
input ?= $(target-name).quickbook ;
local project = [ project.current ] ;
requirements += <testing.arg>$(input:J=" ") ;
local t =
[ targets.create-typed-target RUN_FAIL
: $(project)
: $(target-name)
: ..//quickbook
: $(requirements)
<preserve-test-targets>on
<dependency>$(input)
]
;
modules.poke testing : .all-tests : \$\(all-tests\) $(t) ;
return $(t) ;
}
################################################################################
toolset.flags quickbook-testing.process-quickbook quickbook-command <quickbook-testing.quickbook-command> ;
rule process-quickbook ( target : source : properties * )
{
DEPENDS $(target) : [ on $(target) return $(quickbook-command) ] ;
}
actions process-quickbook bind quickbook-command
{
$(quickbook-command) $(>) --output-file=$(<) --debug
}