def poll_while(self, state, interval=<NUM_LIT:2>):
while self.status() == state:<EOL><INDENT>time.sleep(interval)<EOL><DEDENT>
::

    GET /:login/machines/:id

:param state: (assumed) current state
:type state: :py:class:`basestring`

:param interval: pause in seconds between polls
:type interval: :py:class:`int`

Convenience method that continuously polls the current state of the 
machine remotely, and returns while the machine has the named `state` 
argument. Once the state changes, the method returns. The default wait 
`interval` between requests is 2 seconds, but it may be changed.

.. Note:: If a state transition has not correctly been triggered, this
    method may loop forever.