'Set log file format and check the selected observer.
@param format: The format of the file.
@param expectedObserver: The expected observer.'

def _testLogFormat(self, format, expectedObserver):

    options = TwistOptions()
    options.opt_log_format(format)
    self.assertIdentical(options['fileLogObserverFactory'], expectedObserver)
    self.assertEqual(options['logFormat'], format)
