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

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

416 Axel Bel<strong>in</strong>fante, Lars Frantzen, and Christian Schallhart<br />

implementation. The Co-Op method of deriv<strong>in</strong>g a canonical tester is based on<br />

the above observations.<br />

To slightly formalize the above we can say that the outgo<strong>in</strong>g transitions from<br />

a state s can be divided <strong>in</strong> two sets: Options(s) isthesetofactionsthats can<br />

perform from its unstable states, and Compulsory(s) isasetofofsetsofactions,<br />

where each of the sets of actions corresponds to a stable state that can be reached<br />

from B, and conta<strong>in</strong>s exactly the outgo<strong>in</strong>g actions of that stable state.<br />

The <strong>in</strong>itial behavior from the tester is constructed us<strong>in</strong>g Compulsory and<br />

Options. The tester may <strong>in</strong>itially try to test any of the actions <strong>in</strong> Options(s).<br />

The implementation may <strong>in</strong>teract, but this is not guaranteed. Alternatively (or<br />

after try<strong>in</strong>g several Options), the tester may <strong>in</strong>ternally move to a state from<br />

which it offers to <strong>in</strong>teract with any of a set of actions: this set is chosen such<br />

that it conta<strong>in</strong>s exactly one action of each of the elements of Compulsory(s).<br />

We assume that eventually the implementation moves to one of its stable states,<br />

and from there must be able to perform at least one of the actions offered by the<br />

tester. An implementation that does not <strong>in</strong>teract with<strong>in</strong> some limited time is not<br />

regarded as conform<strong>in</strong>g. If a process s may, after perform<strong>in</strong>g a series of <strong>in</strong>ternal<br />

actions, enter a deadlock<strong>in</strong>g state from which it cannot perform any actions,<br />

Compulsory(s) will conta<strong>in</strong> the empty set. The tester may then try to do any of<br />

the observable outgo<strong>in</strong>g transitions of s, but no <strong>in</strong>teraction is guaranteed. The<br />

tester may then, after try<strong>in</strong>g zero or more actions, deadlock.<br />

The behavior of the tester after do<strong>in</strong>g an action is computed by first collect<strong>in</strong>g<br />

all states subsequent that can be reached by do<strong>in</strong>g that transition, comput<strong>in</strong>g the<br />

<strong>in</strong>itial behavior for the tester from those states (us<strong>in</strong>g Compulsory and Options<br />

as above), and comb<strong>in</strong><strong>in</strong>g these <strong>in</strong>itial behaviors.<br />

To paraphrase: this is about who takes the <strong>in</strong>itiative to force a decision <strong>in</strong> the<br />

case of non determ<strong>in</strong>istic choices. If the specification can decide to do someth<strong>in</strong>g,<br />

the tester must be able to follow, but if the specification leaves the choice to its<br />

environment, the tester can make (force) the decisions. This means that <strong>in</strong> the<br />

result<strong>in</strong>g tester, we see <strong>in</strong>ternal steps where the tester may make a decision (to<br />

select between multiple actions offered from stable states of the implementation),<br />

and actions directly offered (without preced<strong>in</strong>g <strong>in</strong>ternal step) where the tester<br />

must be able to <strong>in</strong>teract directly with actions from unstable states.<br />

User Interaction<br />

Cooper is started with a given specification. It then shows the user this specification,<br />

together with the <strong>in</strong>itial canonical tester for it, which is the canonical<br />

tester derivation function T applied to the whole expression of the specification.<br />

The user can then zoom <strong>in</strong> and step by step apply the canonical tester derivation<br />

function on expressions and subexpressions, every time replac<strong>in</strong>g a sub expression<br />

by its <strong>in</strong>itial tester, which leaves the canonical tester to be applied on<br />

the sub expressions that follows the <strong>in</strong>itial actions <strong>in</strong> <strong>in</strong>itial tester, from which<br />

can then <strong>in</strong> turn the <strong>in</strong>itial tester can be computed, etc.<br />

Cooper allows the user to select a behavior expression, and then computes<br />

the correspond<strong>in</strong>g canonical tester by comput<strong>in</strong>g the tester for the left-hand side

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

Saved successfully!

Ooh no, something went wrong!