Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

GenRocket: what is realistic test data?

 
atul khot
Ranch Hand
Posts: 67
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Gregg,
Does the tool figure it out by some heuristics? Or we tell it the "normal" data ranges -
somehow affecting the generation logic? Heuristics would be great -
- but somehow never thought of/missed would get covered...

--- cheerio atul
 
Gregg Bolinger
Ranch Hand
Posts: 15304
6
Chrome IntelliJ IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
atul,

As far as GenRocket is concerned, realistic test data simply means data that could be conceived as real. To explain this i'll compare it to patterned data. Patterned data, which GenRocket can generate, might look like this:



Realistic data might look like this



The difference is simply a Generator choice. For the realistic data you might choose a NameGen to generate first and last names. Whereas for patterned data you might choose a ConcatGen to join the ID and some other value together.

The important thing to remember is that your test data should be reliable and predictable. You'll need to be able to assert that what you get is what you expect. If you leave too much of that data up to chance and randomness, you will not have very reliable tests.

 
Campbell Ritchie
Sheriff
Pie
Posts: 50258
79
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I presume GenRocket generates wildly inaccurate test figures, too?
 
Gregg Bolinger
Ranch Hand
Posts: 15304
6
Chrome IntelliJ IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Campbell Ritchie wrote:I presume GenRocket generates wildly inaccurate test figures, too?


Hey Campbell! Generating inaccurate or negative test data is subjective and relative. It is only inaccurate because your system rejects it. So to answer your question, absolutely!

For example, if your system rejects obviously fictitious names from new users, you would have a Scenario that generates obviously fictitious names.

If you wanted to make sure email addresses were valid, generate invalid email addresses. We have an EmailGen that creates simple email addresses. Instead of using that Generator, you might use a ConcatGen[/ur] or a [url=http://support.genrocket.com/customer/portal/articles/1465685-listgen]ListGen to formulate invalid data.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic