<s> from __future__ import absolute_import , print_function <EOL> import os <EOL> import re <EOL> import mock <EOL> import mesos . cli . cmds . events <EOL> from . . import utils <EOL> @ mock . patch ( "<STR_LIT>" , utils . sandbox_read ) <EOL> class TestEvents ( utils . MockState ) : <EOL> @ utils . patch_args ( [ <EOL> "<STR_LIT>" , <EOL> "<STR_LIT>" <EOL> ] ) <EOL> @ mock . patch ( "<STR_LIT>" , False ) <EOL> @ mock . patch ( "<STR_LIT>" , os . SEEK_SET ) <EOL> def test_stream ( self ) : <EOL> mesos . cli . cmds . events . main ( ) <EOL> assert len ( re . findall ( "<STR_LIT>" , self . stdout ) ) == <NUM_LIT:2> <EOL> assert len ( re . findall ( "<STR_LIT>" , self . stdout ) ) == <NUM_LIT:1> </s>
