1[/ 2 / Copyright (c) 2003 Boost.Test contributors 3 / 4 / Distributed under the Boost Software License, Version 1.0. (See accompanying 5 / file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) 6 /] 7 8[section:test_case_generation Data-driven test cases] 9 10 11[h4 Why data-driven test cases?] 12Some tests are required to be repeated for a series of different input parameters. One way to achieve this is 13manually register a test case for each parameter. You can also invoke a test function with 14all parameters manually from within your test case, like this: 15 16`` 17void single_test( int i ) 18{ 19 __BOOST_TEST__( /* test assertion */ ); 20} 21 22void combined_test() 23{ 24 int params[] = { 1, 2, 3, 4, 5 }; 25 std::for_each( params, params+5, &single_test ); 26} 27`` 28 29The approach above has several drawbacks: 30 31* the logic for running the tests is inside a test itself: `single_test` in the above example is run from the test 32 case `combined_test` while its execution would be better handled by the __UTF__ 33* in case of fatal failure for one of the values in `param` array above (say a failure in __BOOST_TEST_REQUIRE__), 34 the test `combined_test` is aborted and the next test-case in the test tree is executed. 35* in case of failure, the reporting is not accurate enough: the test should certainly be reran during debugging 36 sessions by a human or additional logic for reporting should be implemented in the test itself. 37 38[h4 Parameter generation, scalability and composition] 39In some circumstance, one would like to run a parametrized test over an /arbitrary large/ set of values. Enumerating the 40parameters by hand is not a solution that scales well, especially when these parameters can be described in another 41function that generates these values. However, this solution has also limitations 42 43* *Generating functions*: suppose we have a function `func(float f)`, where `f` is any number in [0, 1]. We are not 44 interested that much in the exact value, but we would like to test `func`. What about, instead of writing the `f` 45 for which `func` will be tested against, we choose randomly `f` in [0, 1]? And also what about instead of having 46 only one value for `f`, we run the test on arbitrarily many numbers? We easily understand from this small example 47 that tests requiring parameters are more powerful when, instead of writing down constant values in the test, a 48 generating function is provided. 49 50* *Scalability*: suppose we have a test case on `func1`, on which we test `N` values written as constant in the test 51 file. What does the test ensure? We have the guaranty that `func1` is working on these `N` values. Yet in this 52 setting `N` is necessarily finite and usually small. How would we extend or scale `N` easily? One solution is to 53 be able to generate new values, and to be able to define a test on the *class* of possible inputs for `func1` on 54 which the function should have a defined behavior. To some extent, `N` constant written down in the test are just 55 an excerpt of the possible inputs of `func1`, and working on the class of inputs gives more flexibility and power 56 to the test. 57 58* *Composition*: suppose we already have test cases for two functions `func1` and `func2`, taking as argument the 59 types `T1` and `T2` respectively. Now we would like to test a new functions `func3` that takes as argument a type 60 `T3` containing `T1` and `T2`, and calling `func1` and `func2` through a known algorithm. An example of such a 61 setting would be 62 `` 63 // Returns the log of x 64 // Precondition: x strictly positive. 65 double fast_log(double x); 66 67 // Returns 1/(x-1) 68 // Precondition: x != 1 69 double fast_inv(double x); 70 71 struct dummy { 72 unsigned int field1; 73 unsigned int field2; 74 }; 75 76 double func3(dummy value) 77 { 78 return 0.5 * (exp(fast_log(value.field1))/value.field1 + value.field2/fast_inv(value.field2)); 79 } 80 81 `` 82 83 In this example, 84 85 * `func3` inherits from the preconditions of `fast_log` and `fast_inv`: it is defined in `(0, +infinity)` and in `[-C, +C] - {1}` for `field1` and `field2` respectively (`C` 86 being a constant arbitrarily big). 87 * as defined above, `func3` should be close to 1 everywhere on its definition domain. 88 * we would like to reuse the properties of `fast_log` and `fast_inv` in the compound function `func3` and assert that `func3` is well defined over an arbitrary large definition domain. 89 90 Having parametrized tests on `func3` hardly tells us about the possible numerical properties or instabilities close to the point `{field1 = 0, field2 = 1}`. 91 Indeed, the parametrized test may test for some points around (0,1), but will fail to provide an *asymptotic behavior* of the function close to this point. 92 93[h4 Data driven tests in the Boost.Test framework] 94The facilities provided by the __UTF__ addressed the issues described above: 95 96* the notion of *datasets* eases the description of the class of inputs for test cases. The datasets also implement several 97 operations that enable their combinations to create new, more complex datasets, 98* two macros, __BOOST_DATA_TEST_CASE__ and __BOOST_DATA_TEST_CASE_F__, respectively without and with fixture support, 99 are used for the declaration and registration of a test case over a collection of values (samples), 100* each test case, associated to a unique value, is executed independently from others. These tests are guarded in the same 101 way regular test cases are, which makes the execution of the tests over each sample of a dataset isolated, robust, 102 repeatable and ease the debugging, 103* several datasets generating functions are provided by the __UTF__ 104 105The remainder of this section covers the notions and feature provided by the __UTF__ about the data-driven test cases, in 106particular: 107 108# the notion of [link boost_test.tests_organization.test_cases.test_case_generation.datasets *dataset* and *sample*] is introduced 109# [link boost_test.tests_organization.test_cases.test_case_generation.datasets_auto_registration the declaration and registration] 110 of the data-driven test cases are explained, 111# the [link boost_test.tests_organization.test_cases.test_case_generation.operations /operations/] on datasets are detailed 112# and finally the built-in [link boost_test.tests_organization.test_cases.test_case_generation.generators dataset generators] 113 are introduced. 114 115 116[/ ################################################################################################################################## ] 117[section Datasets] 118 119To define properly datasets, the notion of *sample* should be introduced first. A *sample* is defined as /polymorphic tuple/. 120The size of the tuple will be by definition the *arity* of the sample itself. 121 122A *dataset* is a /collection of samples/, that 123 124* is forward iterable, 125* can be queried for its `size` which in turn can be infinite, 126* has an arity which is the arity of the samples it contains. 127 128Hence the dataset implements the notion of /sequence/. 129 130The descriptive power of the datasets in __UTF__ comes from 131 132* the [link boost_test.tests_organization.test_cases.test_case_generation.datasets.dataset_interface interface] for creating a custom datasets, which is quite simple, 133* the [link boost_test.tests_organization.test_cases.test_case_generation.operations operations] they provide for combining different datasets 134* their interface with other type of collections (`stl` containers, `C` arrays) 135* the available built-in [link boost_test.tests_organization.test_cases.test_case_generation.generators /dataset generators/] 136 137[tip Only "monomorphic" datasets are supported, which means that all samples within a single dataset have the same type and same arity 138 [footnote polymorphic datasets will be considered in the future. Their need is mainly driven by the replacement of the 139 [link boost_test.tests_organization.test_cases.test_organization_templates typed parametrized test cases] by the dataset-like API.] 140 . However, dataset of different sample types may be combined together with zip and cartesian product. 141 ] 142 143As we will see in the next sections, datasets representing collections of different types may be combined together (e.g.. /zip/ or /grid/). 144These operations result in new datasets, in which the samples are of an augmented type. 145 146[/ ###################################################################### ] 147 148[section Dataset interface] 149The interface of the /dataset/ should implement the two following functions/fields: 150 151* `iterator begin()` where /iterator/ is a forward iterator, 152* `boost::unit_test::data::size_t size() const` indicates the size of the dataset. The returned type is a dedicated 153 class [classref boost::unit_test::data::size_t size_t] that can indicate an /infinite/ dataset size. 154* an enum called `arity` indicating the arity of the samples returned by the dataset 155 156Once a dataset class `D` is declared, it should be registered to the framework by specializing the template class 157``boost::unit_test::data::monomorphic::is_dataset`` 158with the condition that ``boost::unit_test::data::monomorphic::is_dataset<D>::value`` evaluates to `true`. 159 160The following example implements a custom dataset generating a Fibonacci sequence. 161 162[bt_example dataset_example68..Example of custom dataset..run-fail] 163 164[endsect] 165 166[/ ###################################################################### ] 167 168[section Dataset creation and delayed creation] 169Datasets as defined above are constructed before even the test module starts its execution as global objects. This makes impossible to access, 170from within the dataset generator and during their iteration, elements like `argc` / `argv`, the 171[link boost_test.tests_organization.test_tree.master_test_suite master test suite] (and the preprocessed `argc` / `argv`), or any other object 172that has been instantiated after the `main` of the test module entry. 173 174To overcome this, a [*delayed] dataset instantiation interface has been introduced. This effectively wraps the dataset inside another one, 175which [*lazyly] instantiates the dataset. 176 177To instantiate a delayed dataset, the [funcref boost::unit_test::data::monomorphic::make_delayed] function should be used in the 178__BOOST_DATA_TEST_CASE__ call. The following snippet: 179 180``` 181BOOST_DATA_TEST_CASE(dataset_test_case, 182 boost::unit_test::data::make_delayed<custom_dataset>(arg1, ... ), ...) 183{ 184} 185``` 186 187creates a delayed dataset test case with a generator of type `custom_dataset`. The generator is ['lazily] constructed 188with `arg1`, `...`. 189 190[tip A detailed example of delayed creation is given in the section about [link boost_test.runtime_config.custom_command_line_arguments custom command line] 191 arguments.] 192 193[tip See the class [classref boost::unit_test::data::monomorphic::delayed_dataset `monomorphic::delayed_dataset`] for more details on the 194 wrapping object.] 195 196[endsect] 197 198[endsect] [/ datasets] 199 200 201[/ ################################################################################################################################## ] 202[/ Main code import for this section ] 203[import ../snippet/dataset_1/test_file.cpp] 204 205[/ ################################################################################################################################## ] 206[section:datasets_auto_registration Declaring and registering test cases with datasets] 207In order to declare and register a data-driven test-case, the macros __BOOST_DATA_TEST_CASE__ or __BOOST_DATA_TEST_CASE_F__ 208should be used. Those two forms are equivalent, with the difference that `BOOST_DATA_TEST_CASE_F` supports fixtures. 209 210Those macros are variadic and can be used in the following forms: 211 212`` 213__BOOST_DATA_TEST_CASE__(test_case_name, dataset) { /* dataset1 of arity 1 */ } 214BOOST_DATA_TEST_CASE(test_case_name, dataset, var1) { /* datasets of arity 1 */ } 215BOOST_DATA_TEST_CASE(test_case_name, dataset, var1, ..., varN) { /* datasets of arity N */ } 216 217__BOOST_DATA_TEST_CASE_F__(fixture, test_case_name, dataset) { /* dataset1 of arity 1 with fixture */ } 218BOOST_DATA_TEST_CASE_F(fixture, test_case_name, dataset, var1) { /* dataset1 of arity 1 with fixture */ } 219BOOST_DATA_TEST_CASE_F(fixture, test_case_name, dataset, var1, ..., varN) { /* dataset1 of arity N with fixture */ } 220`` 221 222The first form of the macro is for datasets of arity 1. The value of the sample being executed by the test body is 223available through the automatic variable `sample` (`xrange` is as its name suggests a range of values): 224 225[snippet_dataset1_1] 226 227The second form is also for datasets of arity 1, but instead of the variable `sample`, the current sample is brought into `var1`: 228[snippet_dataset1_2] 229 230The third form is an extension of the previous form for datasets of arity `N`. The sample being a polymorphic tuple, each 231of the variables `var1`, ..., `varN` corresponds to the index 1, ... `N` of the the sample: 232 233[snippet_dataset1_3] 234 235The next three forms of declaration, with `BOOST_DATA_TEST_CASE_F`, are equivalent to the previous ones, with the difference being in the support of 236a fixture that is execute before the test body for each sample. The fixture should follow the expected interface as detailed 237[link boost_test.tests_organization.fixtures.models here]. 238 239The arity of the dataset and the number of variables should be exactly the same, the first form being a short-cut for the 240case of arity 1. 241 242[tip A compilation-time check is performed on the coherence of the arity of the dataset and the number of variables `var1`... `varN`. 243 For compilers *without C++11* support, the maximal supported arity is controlled by the macro 244 __BOOST_TEST_DATASET_MAX_ARITY__, that can be overridden /prior/ to including the __UTF__ headers.] 245 246[caution The macros __BOOST_DATA_TEST_CASE__ and __BOOST_DATA_TEST_CASE_F__ are available only for compilers with support for *variadic macros*.] 247 248[h4 Samples and test tree] 249It should be emphasized that those macros do not declare a single test case (as __BOOST_AUTO_TEST_CASE__ would do) but declare and 250register as many test cases as there are samples in the dataset given in argument. Each test case runs on exactly *one* 251sample of the dataset. 252 253More precisely, what 254``__BOOST_DATA_TEST_CASE__(test_case_name, dataset)`` 255 256does is the following: 257 258* it registers a *test suite* named "`test_case_name`", 259* it registers as many test cases as they are in "`dataset`", each of which with the name corresponding to the index of the sample 260 in the database prefixed by `_` and starting at index `0` ("`_0`", "`_1`", ... "`_(N-1)`" where `N` is the size of the dataset) 261 262This make it easy to: 263 264* identify which sample is failing (say "`test_case_name/_3`"), 265* replay the test for one or several samples (or the full dataset) from the command line using the [link boost_test.runtime_config.test_unit_filtering test filtering features] provided by the __UTF__, 266* apply a [link boost_test.tests_organization.decorators.explicit_decorator_declaration decorator] to each individual test cases of the 267 dataset, as the decorator would apply to the test suite. 268 269Exactly as regular test cases, each test case (associated to a specific sample) is executed in /monitored manner/: 270 271* the test execution are independent: if an error occurs for one sample, the remaining samples execution is not affected, 272* in case of error, the [link boost_test.test_output.test_tools_support_for_logging.contexts context] along with the index of the sample 273 within which the error occurred is reported in the [link boost_test.test_output log]. 274 This context contains the sample names and values for which the test failed, which would ease the debugging. 275 276[endsect] 277 278 279 280 281[/ ################################################################################################################################## ] 282[section:operations Operations on dataset] 283As mentioned earlier, one of the major aspects of using the __UTF__ datasets lies in the number of operations provided 284for their combination. 285 286For that purpose, three operators are provided: 287 288* joins with `operator+` 289* zips with `operator^` on datasets 290* and grids or Cartesian products with `operator*` 291 292[tip All these operators are associative, which enables their combination without parenthesis. However, the precedence rule on the 293operators for the language still apply. ] 294 295[section Joins] 296A ['join], denoted `+`, is an operation on two datasets `dsa` and `dsb` of same arity and compatible types, resulting in the *concatenation* of these two datasets `dsa` and `dsb` 297from the left to the right order of the symbol `+`: 298 299`` 300dsa = (a_1, a_2, ... a_i) 301dsb = (b_1, b_2, ... b_j) 302dsa + dsb = (a_1, a_2, ... a_i, b_1, b_2, ... b_j) 303`` 304 305The following properties hold: 306 307* the resulting dataset is of same arity as the operand datasets, 308* the size of the returned dataset is the sum of the size of the joined datasets, 309* the operation is associative, and it is possible to combine more than two datasets in one expression. The following joins are equivalent for any datasets `dsa`, `dsb` and `dsc`: 310 `` 311 ( dsa + dsb ) + dsc 312 == dsa + ( dsb + dsc ) 313 == dsa + dsb + dsc 314 `` 315 316[warning In the expression `dsa + dsb`, `dsa` and/or `dsb` can be of infinite size. The resulting dataset will have an infinite size as well. If `dsa` is infinite, the content of 317 `dsb` will never be reached. ] 318 319[bt_example dataset_example62..Example of join on datasets..run] 320 321[endsect] 322 323 324[section Zips] 325A ['zip], denoted `^` , is an operation on two datasets `dsa` and `dsb` of same arity and same size, resulting in a dataset where the `k`-th sample of `dsa` is paired with the corresponding `k`-th sample of `dsb`. 326The resulting dataset samples order follows the left to right order against the symbol `^`. 327 328`` 329dsa = (a_1, a_2, ... a_i) 330dsb = (b_1, b_2, ... b_i) 331dsa ^ dsb = ( (a_1, b_1), (a_2, b_2) ... (a_i, b_i) ) 332`` 333 334The following properties hold: 335 336* the arity of the resulting dataset is the sum of the arities of the operand datasets, 337* the size of the resulting dataset is equal to the size of the datasets (since they are supposed to be of the same size), 338 exception made for the case the operand datasets size mismatch (see below), 339* the operation is associative, and it is possible to combine more than two datasets in one expression, 340 `` 341 ( dsa ^ dsb ) ^ dsc 342 == dsa ^ ( dsb ^ dsc ) 343 == dsa ^ dsb ^ dsc 344 `` 345 346A particular handling is performed if `dsa` and `dsb` are of different size. The rule is as follow: 347 348* if the both zipped datasets have the same size, this is the size of the resulting dataset (this size can then be infinite). 349* otherwise if one of the dataset is of size 1 (singleton) or of infinite size, the resulting size is governed by the other dataset. 350* otherwise an exception is thrown at runtime 351 352 353[caution If the /zip/ operation is not supported for your compiler, the macro [macroref BOOST_TEST_NO_ZIP_COMPOSITION_AVAILABLE `BOOST_TEST_NO_ZIP_COMPOSITION_AVAILABLE`] 354 will be automatically set by the __UTF__] 355 356[bt_example dataset_example61..Example of zip on datasets..run] 357 358 359[endsect] [/ zip operation on datasets] 360 361 362 363[section Grid (Cartesian products)] 364A ['grid], denoted `*` , is an operation on two any datasets `dsa` and `dsb` resulting in a dataset where each sample of `dsa` is paired with each sample of `dsb` 365exactly once. The resulting dataset samples order follows the left to right order against the symbol `*`. The rightmost dataset samples are iterated first. 366 367`` 368dsa = (a_1, a_2, ... a_i) 369dsb = (b_1, b_2, ... b_j) 370dsa * dsb = ((a_1, b_1), (a_1, b_2) ... (a_1, b_j), (a_2, b_1), ... (a_2, b_j) ... (a_i, b_1), ... (a_i, b_j)) 371`` 372 373The grid hence is similar to the mathematical notion of Cartesian product [footnote if the sequence is viewed as a set]. 374 375The following properties hold: 376 377* the arity of the resulting dataset is the sum of the arities of the operand datasets, 378* the size of the resulting dataset is the product of the sizes of the datasets, 379* the operation is associative, and it is possible to combine more than two datasets in one expression, 380* as for /zip/, there is no need the dataset to have the same type of samples. 381 382[caution If the /grid/ operation is not supported for your compiler, the macro [macroref BOOST_TEST_NO_GRID_COMPOSITION_AVAILABLE `BOOST_TEST_NO_GRID_COMPOSITION_AVAILABLE`] 383 will be automatically set by the __UTF__] 384 385In the following example, the random number generator is the second dataset. Its state is evaluated 6 times (3 times for the first `xrange` - first dimension - 386and twice for the second `xrange` - second dimension - to which it is zipped). Note that the state of the random engine is 387not copied between two successive evaluations of the first dimension. 388 389[bt_example dataset_example64..Example of Cartesian product..run-fail] 390 391 392[endsect] 393 394 395 396 397[endsect] [/ operations on dataset] 398 399 400 401[/ ################################################################################################################################## ] 402[section:generators Datasets generators] 403Several ['generators] for datasets are implemented in __UTF__: 404 405* [link boost_test.tests_organization.test_cases.test_case_generation.generators.singletons Singletons] 406* [link boost_test.tests_organization.test_cases.test_case_generation.generators.stl `forward iterable`] containers and 407 [link boost_test.tests_organization.test_cases.test_case_generation.generators.c_arrays `C` array] like datasets 408* [link boost_test.tests_organization.test_cases.test_case_generation.generators.ranges ranges] or sequences of values 409* datasets made of [link boost_test.tests_organization.test_cases.test_case_generation.generators.random random numbers] and following a particular distribution 410 411`stl` and `C-array` generators are merely a dataset view on existing collection, while ranges and random number sequences are 412describing new datasets. 413 414 415[/ ################################################################################################################################## ] 416[h4:singletons Singletons] 417 418A singleton is a dataset containing a unique value. The size and arity of such a dataset is 1. This value can be 419 420* either consumed once 421* or repeated as many times as needed in a zip operation 422 423As mentioned in /zip/, when zipped with a distribution of infinite size, the resulting dataset will have 424a size of 1. 425 426The singleton is constructible through the function [funcref boost::unit_test::data::make]. 427 428[bt_example dataset_example65..Singleton..run] 429 430 431 432[/ ################################################################################################################################## ] 433[h4:c_arrays Datasets from C arrays] 434This type of datasets does not contains the logic for generating the sequence of values, and is used as a wrapper on an existing 435sequence contained in a `C` array. The arity is 1 and the size is the size of the array. 436 437Such datasets are simply constructed from an overload of the [funcref boost::unit_test::data::make `make`] function. 438 439[bt_example dataset_example66..Array..run] 440 441[/ ################################################################################################################################## ] 442[h4:stl Datasets from forward iterable containers] 443As for `C` arrays, this type of datasets does not contain the logic for generating sequence of values, and are used for parsing an existing sequence. 444The arity is 1 and the size is the same as the one of the container. 445 446 447[tip C++11 implementation enables the dataset generation from any container which iterator implements the forward iterator concept. 448 For C++03, the feature is enabled on most STL containers.] 449 450[bt_example dataset_example67..Dataset from `std::vector` and `std::map`..run] 451 452 453 454[/ ################################################################################################################################## ] 455[h4:ranges Ranges] 456A range is a dataset that implements a sequence of equally spaced values, defined by a /start/, and /end/ and a /step/. 457 458It is possible to construct a range using the factory [funcref boost::unit_test::data::xrange], available in the overloads below: 459 460`` 461#include <boost/test/data/test_case.hpp> 462#include <boost/test/data/monomorphic.hpp> 463 464auto range1 = data::xrange( (data::step = 0.5, data::end = 3 ) ); // Constructs with named values, starting at 0 465auto range2 = data::xrange( begin, end ); // begin < end required 466auto range5 = data::xrange( begin, end, step ); // begin < end required 467auto range3 = data::xrange( end ); // begin=0, end cannot be <= 0, see above 468auto range4 = data::xrange( end, (data::begin=1) ); // named value after end 469`` 470 471[tip The named value parameters should be declared inside parenthesis] 472 473[h5 Parameters] 474The details of the named value parameters is given in the table below. 475[table:id_range_parameter_table Range parameters 476 [ 477 [Name] 478 [Default] 479 [Description] 480 ] 481 [ 482 [`begin`] 483 [0] 484 [Beginning of the generated sequence. The `begin` value is included in set of values returned 485 by the generator. 486 ] 487 ] 488 489 [ 490 [`end`] 491 [+ infinity] 492 [End of the generated sequence. The `end` value is not included in set of values returned 493 by the generator. If omitted, the generator has infinite size. 494 ] 495 ] 496 497 [ 498 [`step`] 499 [1] 500 [Number indicating the step between two consecutive samples of the generated range. 501 The default type is the same as the input type. This value should not be 0. It should be of the same 502 sign as `end-begin`. 503 ] 504 ] 505] 506 507[bt_example dataset_example59..Declaring a test with a range..run-fail] 508 509 510 511[/ ################################################################################################################################## ] 512[h4:random Random value dataset] 513 514This type of dataset generates a sequence of random numbers following a given /distribution/. The /seed/ and the /engine/ may also be 515specified. 516 517 518[caution The random value generator is available only for C++11 capable compilers. If this feature is not supported for your compiler, 519 the macro [macroref BOOST_TEST_NO_RANDOM_DATASET_AVAILABLE `BOOST_TEST_NO_RANDOM_DATASET_AVAILABLE`] 520 will be automatically set by the __UTF__] 521 522 523 524It is possible to construct a random sequence using the factory [funcref boost::unit_test::data::random], available in the overloads below: 525 526`` 527auto rdgen = random(); // uniform distribution (real) on [0, 1) 528auto rdgen = random(1, 17); // uniform distribution (integer) on [1, 17] 529// Default random generator engine, Gaussian distribution (mean=5, sigma=2) and seed set to 100. 530auto rdgen = random( (data::seed = 100UL, 531 data::distribution = std::normal_distribution<>(5.,2)) ); 532`` 533 534Since the generated datasets will have infinite size, the sequence size should be narrowed by combining the dataset with another 535one through e.g. a /zip/ operation. 536 537[tip In order to be able to reproduce a failure within a randomized parameter test case, the seed that generated the failure may be 538set in order to generate the same sequence of random values.] 539 540[h5 Parameters] 541The details of the named value parameters is given in the table below. 542[table:id_range_parameter_table Range parameters 543 [ 544 [Parameter name] 545 [Default] 546 [Description] 547 ] 548 [ 549 [`seed`] 550 [(not set)] 551 [Seed for the generation of the random sequence.] 552 ] 553 [ 554 [`distribution`] 555 [Uniform] 556 [Distribution instance for generating the random number sequences. The `end` value is not included in set of values returned 557 by the generator for real values, and is included for integers. ] 558 ] 559 [ 560 [`engine`] 561 [`std::default_random_engine`] 562 [Random number generator engine.] 563 ] 564] 565 566[bt_example dataset_example63..Declaring a test with a random sequence..run-fail] 567 568 569[endsect] [/ Datasets generators] 570 571[endsect] 572