lib.fileset.unions: Fix outdated docs
Since 4f35f003e6 unions supports empty lists too
This commit is contained in:
@@ -258,7 +258,6 @@ If a directory does not recursively contain any file, it is omitted from the sto
|
|||||||
*/
|
*/
|
||||||
unions =
|
unions =
|
||||||
# A list of file sets.
|
# A list of file sets.
|
||||||
# Must contain at least 1 element.
|
|
||||||
# The elements can also be paths,
|
# The elements can also be paths,
|
||||||
# which get [implicitly coerced to file sets](#sec-fileset-path-coercion).
|
# which get [implicitly coerced to file sets](#sec-fileset-path-coercion).
|
||||||
filesets:
|
filesets:
|
||||||
|
|||||||
@@ -415,7 +415,7 @@ expectFailure 'toSource { root = ./.; fileset = union ./. ./b; }' 'lib.fileset.u
|
|||||||
expectFailure 'toSource { root = ./.; fileset = unions [ ./a ./. ]; }' 'lib.fileset.unions: element 0 \('"$work"'/a\) does not exist.'
|
expectFailure 'toSource { root = ./.; fileset = unions [ ./a ./. ]; }' 'lib.fileset.unions: element 0 \('"$work"'/a\) does not exist.'
|
||||||
expectFailure 'toSource { root = ./.; fileset = unions [ ./. ./b ]; }' 'lib.fileset.unions: element 1 \('"$work"'/b\) does not exist.'
|
expectFailure 'toSource { root = ./.; fileset = unions [ ./. ./b ]; }' 'lib.fileset.unions: element 1 \('"$work"'/b\) does not exist.'
|
||||||
|
|
||||||
# unions needs a list with at least 1 element
|
# unions needs a list
|
||||||
expectFailure 'toSource { root = ./.; fileset = unions null; }' 'lib.fileset.unions: Expected argument to be a list, but got a null.'
|
expectFailure 'toSource { root = ./.; fileset = unions null; }' 'lib.fileset.unions: Expected argument to be a list, but got a null.'
|
||||||
|
|
||||||
# The tree of later arguments should not be evaluated if a former argument already includes all files
|
# The tree of later arguments should not be evaluated if a former argument already includes all files
|
||||||
|
|||||||
Reference in New Issue
Block a user