diff options
author | Daniel Stenberg <daniel@haxx.se> | 2020-10-04 00:03:02 +0200 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2020-10-04 17:16:53 +0200 |
commit | b8e4d1cb0ab3a35c768d85d099cdd0603325726f (patch) | |
tree | 3f4a086a0d2fa621f60291d1a70bccd3b5c4ffc4 /tests/FILEFORMAT.md | |
parent | 639c6bfcfa53248fb606f7357693710dc076593a (diff) | |
download | curl-b8e4d1cb0ab3a35c768d85d099cdd0603325726f.tar.gz |
runtests: add %repeat[]% for test files
... and use this new keywords in all the test files larger than 50K to reduce
their sizes and make them a lot easier to read and understand.
Closes #6040
Diffstat (limited to 'tests/FILEFORMAT.md')
-rw-r--r-- | tests/FILEFORMAT.md | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/tests/FILEFORMAT.md b/tests/FILEFORMAT.md index c2cc1016e..0f66de277 100644 --- a/tests/FILEFORMAT.md +++ b/tests/FILEFORMAT.md @@ -53,6 +53,21 @@ For example, to insert the binary octets 0, 1 and 255 into the test file: %hex[ %00%01%FF ]hex% +## Repeat content + +In the preprocess stage, a special instruction can be used to have runtests.pl +generate a repetetive sequence of bytes. + +To insert a sequence of repeat bytes, use this syntax to make the `<string>` +get repeated `<number>` of times. The number has to be 1 or large and the +string may contain `%HH` hexadecimal codes: + + %repeat[<number> x <string>]% + +For example, to insert the word hello a 100 times: + + %repeat[100 x hello]% + # Variables When the test is preprocessed, a range of "variables" in the test file will be |