Пример #1
0
def feeder_run(o):
    if o['list']:
        if o['fake']:
            list_fake_types()
        elif o['transports']:
            list_transports()
        elif o['formatters']:
            list_formatters()

    elif o['feed']:
        generator(config=o.get('--config'),
                  transport=o.get('--transport'),
                  formatter=o.get('--format'),
                  gap=o.get('--gap'),
                  messages=o.get('--messages'),
                  batch=o.get('--batch'),
                  verbose=o.get('--verbose'))
Пример #2
0
def feeder_run(o):
    if o['list']:
        if o['fake']:
            list_fake_types()
        elif o['transports']:
            list_transports()
        elif o['formatters']:
            list_formatters()

    elif o['feed']:
        generator(config=o.get('--config'),
                 transport=o.get('--transport'),
                 formatter=o.get('--format'),
                 gap=o.get('--gap'),
                 messages=o.get('--messages'),
                 batch=o.get('--batch'),
                 verbose=o.get('--verbose'))
Пример #3
0
 def test_generator_stream(self):
     fd.generator(transport='Stream', messages=1)
Пример #4
0
 def test_generator_formatter_apacheerror(self):
     fd.generator(formatter='ApacheError', messages=1)
Пример #5
0
 def test_generator_transport_udp(self):
     fd.generator(transport='MyUDPTransport',
                  config=MOCK_CONFIG_FILE,
                  messages=1)
Пример #6
0
 def test_generator_formatter_json(self):
     fd.generator(formatter='Json', messages=1)
Пример #7
0
 def test_generator_formatter_apacheaccess(self):
     fd.generator(formatter='ApacheAccess', messages=1)
Пример #8
0
 def test_generator_stream(self):
     fd.generator(transport='Stream', messages=1)
Пример #9
0
 def test_generator_defaults(self):
     fd.generator(verbose=True, messages=1)
Пример #10
0
 def test_generator_transport_udp(self):
     fd.generator(transport='MyUDPTransport', config=MOCK_CONFIG_FILE,
                  messages=1)
Пример #11
0
 def test_generator_formatter_apacheerror(self):
     fd.generator(formatter='ApacheError', messages=1)
Пример #12
0
 def test_generator_formatter_apacheaccess(self):
     fd.generator(formatter='ApacheAccess', messages=1)
Пример #13
0
 def test_generator_formatter_json(self):
     fd.generator(formatter='Json', messages=1)
Пример #14
0
 def test_generator_defaults(self):
     fd.generator(verbose=True, messages=1)