07.01.2013 Views

Lecture Notes in Computer Science 3472

Lecture Notes in Computer Science 3472

Lecture Notes in Computer Science 3472

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

14 Tools for Test Case Generation 405<br />

correspond<strong>in</strong>g values are chosen randomly aga<strong>in</strong> to obta<strong>in</strong> a complete test sequence.<br />

The test sequence generation is implemented <strong>in</strong> Prolog and based on the<br />

ECLiPSE package [ECLb].<br />

Doma<strong>in</strong> Splitt<strong>in</strong>g<br />

The basic test<strong>in</strong>g method described above allows to generate a s<strong>in</strong>gle test sequence.<br />

GATeL offers the possibility of “doma<strong>in</strong> splitt<strong>in</strong>g”, i.e., to replace the<br />

doma<strong>in</strong> (described by the current constra<strong>in</strong>t set) with two ore more sub-doma<strong>in</strong>s<br />

(aga<strong>in</strong> described by constra<strong>in</strong>t sets) which are special cases of the orig<strong>in</strong>al doma<strong>in</strong><br />

(see Section 12.2 on page 324).<br />

For example if the constra<strong>in</strong>t set conta<strong>in</strong>s the condition A = B C. Doma<strong>in</strong> splitt<strong>in</strong>g can be applied recursively to<br />

obta<strong>in</strong> a tree of sub-doma<strong>in</strong>s of the orig<strong>in</strong>al doma<strong>in</strong>.<br />

Once the user decides to stop the doma<strong>in</strong> splitt<strong>in</strong>g, GATeL will produce a test<br />

sequence for each sub-doma<strong>in</strong> (if possible).<br />

Summary<br />

GATeL does not only allow to state <strong>in</strong>variance properties but allows to state<br />

path predicates to express the test purpose. To support path predicates, GATeL<br />

has to construct its test sequences backwards, i.e., it has to start with the f<strong>in</strong>al<br />

state to be reached by the test sequence. Thus the test sequence is not generated<br />

dur<strong>in</strong>g the execution of the SUT, but before the SUT is executed.<br />

This backward search is implemented <strong>in</strong> terms of a backtrack<strong>in</strong>g algorithm. The<br />

backtrack<strong>in</strong>g algorithm has to guess appropriate assignments when the current<br />

constra<strong>in</strong>t set does not enforce a particular assignment or does not allows further<br />

simplification.<br />

Moreover, GATeL requires the SUT to be given as Lustre source code, represent<strong>in</strong>g<br />

either the actual implementation or its complete specification. Aga<strong>in</strong>, this is<br />

necessary, s<strong>in</strong>ce GATeL has to construct its test sequences backwards.<br />

The feature of doma<strong>in</strong> splitt<strong>in</strong>g allows to further subdivide the doma<strong>in</strong> of <strong>in</strong>terest<strong>in</strong>g<br />

test sequences <strong>in</strong>teractively. Moreover, it requires human <strong>in</strong>tervention,<br />

which does not allow to generate a large number of sub-doma<strong>in</strong>s automatically.<br />

F<strong>in</strong>ally, the doma<strong>in</strong> splitt<strong>in</strong>g applies to the <strong>in</strong>itial constra<strong>in</strong>t set, which primarily<br />

constra<strong>in</strong>s the very last cycles of the test sequence. Consequently, the doma<strong>in</strong><br />

splitt<strong>in</strong>g as implemented by GATeL only allows to split the doma<strong>in</strong> wrt. the end<br />

of the test sequence.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!