diff --git a/www/documentation/generated.html b/www/documentation/generated.html index 3789ca3..7b2ca14 100644 --- a/www/documentation/generated.html +++ b/www/documentation/generated.html @@ -109,7 +109,7 @@

The import element

Content model:
-

The scenario element

Content model:
call?
scenario*
pending*
context*
expect*
Content attributes:
focus?
label
Zero or more attributes from any namespace.
+

The scenario element

Content model:
call?
scenario*
pending*
context*
expect*
Content attributes:
focus?
label
xfail?
Zero or more attributes from any namespace.

A scenario groups together the definition of the script environment (the call element) and the script assertions (the context and @@ -125,6 +125,11 @@

The scenario element

Content model: reported. When present, only that assertion or scenario will be evaluated. Its content describes why you are focusing on this particular assertion or scenario.

The label attribute is used to describe the current element in human-readable words.

+

Assertions with the xfail attribute will behave just like other assertions, but + will succeed where other assertions fail, and will fail where other assertions succeed (i.e. the result is inverted). + The xfail attribute can also be applied to scenarios, in which case xfail will be implicitly + set to true for all of the scenarios assertions. + The value of the xfail attribute must be true.

@@ -164,7 +169,7 @@

The context element

Content model:<
-

The expect element

Content model:
document*
Content attributes:
equals?
focus?
grammar?
href?
label?
max?
min?
normalize-space?
pending?
step?
test?
type?
Zero or more attributes from any namespace.
+

The expect element

Content model:
document*
Content attributes:
equals?
focus?
grammar?
href?
label?
max?
min?
normalize-space?
pending?
step?
test?
type?
xfail?
Zero or more attributes from any namespace.

Defines what is expected from the context document(s).

@@ -237,6 +242,11 @@

The expect element

Content model: +

Assertions with the xfail attribute will behave just like other assertions, but + will succeed where other assertions fail, and will fail where other assertions succeed (i.e. the result is inverted). + The xfail attribute can also be applied to scenarios, in which case xfail will be implicitly + set to true for all of the scenarios assertions. + The value of the xfail attribute must be true.

diff --git a/www/documentation/index.html b/www/documentation/index.html index ba81009..614423c 100644 --- a/www/documentation/index.html +++ b/www/documentation/index.html @@ -187,7 +187,7 @@

xprocspec

A tool for testing XProc scripts

-

Unofficial Draft

+

Unofficial Draft

@@ -263,7 +263,7 @@

-

1.3 The scenario element

Content model:
call?
scenario*
pending*
context*
expect*
Content attributes:
focus?
label
Zero or more attributes from any namespace.
+

1.3 The scenario element

Content model:
call?
scenario*
pending*
context*
expect*
Content attributes:
focus?
label
xfail?
Zero or more attributes from any namespace.

A scenario groups together the definition of the script environment (the call element) and the script assertions (the context and @@ -279,6 +279,11 @@

The label attribute is used to describe the current element in human-readable words.

+

Assertions with the xfail attribute will behave just like other assertions, but + will succeed where other assertions fail, and will fail where other assertions succeed (i.e. the result is inverted). + The xfail attribute can also be applied to scenarios, in which case xfail will be implicitly + set to true for all of the scenarios assertions. + The value of the xfail attribute must be true.

@@ -318,7 +323,7 @@

-

1.7 The expect element

Content model:
document*
Content attributes:
equals?
focus?
grammar?
href?
label?
max?
min?
normalize-space?
pending?
step?
test?
type?
Zero or more attributes from any namespace.
+

1.7 The expect element

Content model:
document*
Content attributes:
equals?
focus?
grammar?
href?
label?
max?
min?
normalize-space?
pending?
step?
test?
type?
xfail?
Zero or more attributes from any namespace.

Defines what is expected from the context document(s).

@@ -391,6 +396,11 @@

+

Assertions with the xfail attribute will behave just like other assertions, but + will succeed where other assertions fail, and will fail where other assertions succeed (i.e. the result is inverted). + The xfail attribute can also be applied to scenarios, in which case xfail will be implicitly + set to true for all of the scenarios assertions. + The value of the xfail attribute must be true.

diff --git a/xprocspec/src/it/it-xprocspec/src/test/xprocspec/tests/expect-1.xprocspec b/xprocspec/src/it/it-xprocspec/src/test/xprocspec/tests/expect-1.xprocspec index f63f06b..dc7eaaf 100644 --- a/xprocspec/src/it/it-xprocspec/src/test/xprocspec/tests/expect-1.xprocspec +++ b/xprocspec/src/it/it-xprocspec/src/test/xprocspec/tests/expect-1.xprocspec @@ -1,17 +1,17 @@ - + - + - + @@ -25,7 +25,7 @@ - + @@ -47,7 +47,7 @@ - + @@ -63,9 +63,9 @@ - + - + @@ -77,8 +77,37 @@ - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - + diff --git a/xprocspec/src/main/resources/content/xml/schema/xprocspec.rng b/xprocspec/src/main/resources/content/xml/schema/xprocspec.rng index 3134f96..8761131 100644 --- a/xprocspec/src/main/resources/content/xml/schema/xprocspec.rng +++ b/xprocspec/src/main/resources/content/xml/schema/xprocspec.rng @@ -114,6 +114,9 @@ + + + @@ -262,6 +265,9 @@ + + + @@ -662,6 +668,19 @@ + + + +

Assertions with the xfail attribute will behave just like other assertions, but + will succeed where other assertions fail, and will fail where other assertions succeed (i.e. the result is inverted). + The xfail attribute can also be applied to scenarios, in which case xfail will be implicitly + set to true for all of the scenarios assertions. + The value of the xfail attribute must be true.

+
+ true +
+
+ diff --git a/xprocspec/src/main/resources/content/xml/xproc/evaluate/evaluate.xpl b/xprocspec/src/main/resources/content/xml/xproc/evaluate/evaluate.xpl index 1c1472d..00a1712 100644 --- a/xprocspec/src/main/resources/content/xml/xproc/evaluate/evaluate.xpl +++ b/xprocspec/src/main/resources/content/xml/xproc/evaluate/evaluate.xpl @@ -1,17 +1,17 @@ - + - + - + @@ -276,7 +276,8 @@ - + @@ -385,7 +386,7 @@ - + @@ -407,7 +408,7 @@ - + @@ -440,7 +441,7 @@ - + @@ -460,6 +461,21 @@ + + + + + + + + + + + + + + + diff --git a/xprocspec/src/main/resources/content/xml/xproc/preprocess/preprocess.xpl b/xprocspec/src/main/resources/content/xml/xproc/preprocess/preprocess.xpl index d725605..33c7ef1 100644 --- a/xprocspec/src/main/resources/content/xml/xproc/preprocess/preprocess.xpl +++ b/xprocspec/src/main/resources/content/xml/xproc/preprocess/preprocess.xpl @@ -727,6 +727,20 @@ + + + + + + + + + + + + + +