Progmasoft Git

catch3

Progmasoft Catch3: an independently maintained C++17 test framework with a parallel runner, property checks, snapshots and structured results.

Clonegit clone https://git.progmasoft.com/catch3

Update Approx documentation

Commit
a49e6fdc2779f4427549b784f8f6c72d3cffdbce
Author
Martin Hořeňovský ·
Parents
accf9859b412

Files · Download .tar.gz

Changes

 docs/assertions.md | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/docs/assertions.md b/docs/assertions.md
index 3a9d898e..93f88c41 100644
--- a/docs/assertions.md
+++ b/docs/assertions.md
@@ -64,7 +64,7 @@ This way `Approx` is constructed with reasonable defaults, covering most simple
 
 * __epsilon__ - epsilon serves to set the percentage by which a result can be erroneous, before it is rejected. By default set to `std::numeric_limits<float>::epsilon()*100`.
 * __margin__ - margin serves to set the the absolute value by which a result can be erroneous before it is rejected. By default set to `0.0`.
-* __scale__ - scale serves to adjust the base for comparison used by epsilon, can be used when  By default set to `1.0`.
+* __scale__ - scale serves to adjust the epsilon's multiplicator. By default set to `0.0`.
 
 #### epsilon example
 ```cpp
@@ -84,7 +84,12 @@ Approx target = Approx(100).margin(5);
 ```
 
 #### scale
-Scale can be useful if the computation leading to the result worked on different scale, than is used by the results (and thus expected errors are on a different scale than would be expected based on the results alone).
+Scale can be useful if the computation leading to the result worked
+on different scale than is used by the results. Since allowed difference
+between Approx's value and compared value is based primarily on Approx's value
+(the allowed difference is computed as
+`(Approx::scale + Approx::value) * epsilon`), the resulting comparison could
+need rescaling to be correct.
 
 
 ## Exceptions