[ 
https://issues.apache.org/jira/browse/PDFBOX-2034?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Tilman Hausherr updated PDFBOX-2034:
------------------------------------

    Description: 
This is a follow-up of PDFBOX-1977, which was created by John.
====
TestFilters uses Random().nextLong() to generate a seed for random data, which 
means that it is non-determinate. Depending on the seed value, the test may 
fail or succeed.
====
So what we need is:
- a set of [deterministic 
tests|http://martinfowler.com/articles/nonDeterminism.html]
- a set of non-deterministic tests

To see why, see the discussion in PDFBOX-1977.

  was:
This is a follow-up of PDFBOX-1977, which was created by John.
====
TestFilters uses Random().nextLong() to generate a seed for random data, which 
means that it is non-determinate. Depending on the seed value, the test may 
fail or succeed.

Using the following seed resulted in the LZW filter failing (this has been 
resolved in PDFBOX-1977):
final long seed = -6257105096642706464L;
====
So what we need is:
- a test that uses the seed above (one should temporarly recreate the mentioned 
LZW filter bug to see that the test does indeed create a sequence so that it 
fails!), alternatively save the exact sequence from PDFBOX-1977 into a file and 
pass it through the filter
- a set of [deterministic 
tests|http://martinfowler.com/articles/nonDeterminism.html]
- a set of non-deterministic tests

To see why, see the discussion in PDFBOX-1977.


> TestFilters is non-deterministic
> --------------------------------
>
>                 Key: PDFBOX-2034
>                 URL: https://issues.apache.org/jira/browse/PDFBOX-2034
>             Project: PDFBox
>          Issue Type: Improvement
>    Affects Versions: 1.8.5, 2.0.0
>            Reporter: Tilman Hausherr
>            Priority: Minor
>              Labels: LZW
>
> This is a follow-up of PDFBOX-1977, which was created by John.
> ====
> TestFilters uses Random().nextLong() to generate a seed for random data, 
> which means that it is non-determinate. Depending on the seed value, the test 
> may fail or succeed.
> ====
> So what we need is:
> - a set of [deterministic 
> tests|http://martinfowler.com/articles/nonDeterminism.html]
> - a set of non-deterministic tests
> To see why, see the discussion in PDFBOX-1977.



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Reply via email to