Module Expr Str Import alias Import alias identifier ImportFrom alias Import alias identifier Assign AttributeStore NameLoad attr NameLoad Assign NameStore Call AttributeLoad NameLoad attr FunctionDef arguments args NameParam NameParam NameParam defaults body Expr Str If CompareEq NameLoad Str body FunctionDef arguments args defaults body Assign TupleStore NameStore NameLoad Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr TupleLoad Str TupleLoad NameLoad Expr Call AttributeLoad NameLoad attr decorator_list Assign NameStore Call AttributeLoad NameLoad attr keyword NameLoad Expr Call AttributeLoad NameLoad attr Return NameLoad orelse If CompareEq NameLoad Str body FunctionDef arguments args defaults body Assign TupleStore NameStore NameLoad Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr TupleLoad Str TupleLoad NameLoad Expr Call AttributeLoad NameLoad attr decorator_list Assign NameStore Call AttributeLoad NameLoad attr keyword NameLoad Expr Call AttributeLoad NameLoad attr Return NameLoad orelse Raise NameLoad BinOpMod Str NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str Global identifier Expr Call AttributeLoad NameLoad attr IfExp NameLoad NameLoad NameLoad If Call AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr decorator_list
N/A N/A 
stepper_a - asynchronous stepper using threads.

Controllable/observable, asynchronous, non-deterministic stepper for Socket
(see stepper.py header and README.txt for explanations).

In this stepper the _return actions are observable, not controllable.
Therefore this stepper supports nondeterminism in return values.

In the test_action branch for each controllable action, the code for
the _call action constructs the observed _return action, which may
include nondeterministic return values.  It appends the _return action
to the observation queue.

Then pmt pops the _return action from the observation queue, then
calls the model to determine whether the observed _return action is
enabled.  So pmt + model determines whether the test passed or failed.
This simplifies the stepper (compare test_action branch for
recv_call/return here to stepper_d.py).

This stepper is asynchronous - a _call action need not be immediately
followed by its _return action.  Each _call is handled in its own thread,
so test_action can return even if _call blocks.

Example: pmt -i stepper_a ...
 N/A threading N/A stepper_util connection stepper_util reset N/A observation_queue observation N/A N/A observation asynch True N/A event N/A N/A threading Event test_action N/A N/A aname args modelResult N/A N/A N/A 
  In the test_action branch for each controllable action, the code for
  the _call action waits (synchronously) for the implemenation to 
  return, then uses the observed return value to construct and return 
  the _return action (which may include nondeterministic return values).
   N/A N/A aname send_call N/A wait_for_return N/A N/A N/A N/A N/A N/A msg args N/A nchars N/A N/A N/A connection sender send msg N/A N/A N/A N/A observation queue append N/A send_return N/A nchars N/A N/A N/A event set N/A N/A t N/A N/A threading Thread target wait_for_return N/A N/A N/A t start N/A None N/A N/A N/A aname recv_call N/A wait_for_return N/A N/A N/A N/A N/A N/A bufsize args N/A data N/A N/A N/A connection receiver recv bufsize N/A N/A N/A N/A observation queue append N/A recv_return N/A data N/A N/A N/A event set N/A N/A t N/A N/A threading Thread target wait_for_return N/A N/A N/A t start N/A None N/A N/A NotImplementedError N/A action not supported by stepper: %s aname N/A wait N/A N/A timeout N/A N/A N/A 
    wait for event with timeout.  If event occurs, clear event

    This function must be present in any stepper that sets 
     observation.asynch = True
    
    This function is called from the test runner pmt, 
     the event is hidden in this module.
     N/A event N/A N/A N/A event wait N/A timeout timeout None N/A N/A N/A event is_set N/A N/A N/A N/A event clear N/A