<s> import os <EOL> import sys <EOL> import unittest <EOL> from flexmock import flexmock <EOL> sys . path . append ( os . path . join ( os . path . dirname ( __file__ ) , "<STR_LIT>" ) ) <EOL> from brokers import rabbitmq <EOL> sys . path . append ( os . path . join ( os . path . dirname ( __file__ ) , "<STR_LIT>" ) ) <EOL> import file_io <EOL> class TestBrokerRabbitMQ ( unittest . TestCase ) : <EOL> """<STR_LIT>""" <EOL> def test_get_rabbitmq_location ( self ) : <EOL> flexmock ( file_io ) . should_receive ( "<STR_LIT>" ) . and_return ( "<STR_LIT>" ) <EOL> flexmock ( file_io ) . should_receive ( "<STR_LIT>" ) . and_return ( None ) <EOL> expected = "<STR_LIT>" <EOL> self . assertEquals ( rabbitmq . get_connection_string ( ) , expected ) <EOL> if __name__ == "<STR_LIT:__main__>" : <EOL> unittest . main ( ) </s>
