From 6c1e50e0b545382cecfbb29a9c94b8f7d30c58e8 Mon Sep 17 00:00:00 2001 From: Jaime Soriano Pastor Date: Wed, 29 Aug 2018 17:12:32 +0200 Subject: [PATCH] Force input to file in filebeat module tests There can be modules that support multiple inputs, currently we only support module tests with file input so modules whose default input is a different one fails. This change assumes that a `var.input` setting is used to select the input, and sets it to file on tests. --- filebeat/tests/system/test_modules.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/filebeat/tests/system/test_modules.py b/filebeat/tests/system/test_modules.py index 456acabda66d..b12e01a7032f 100644 --- a/filebeat/tests/system/test_modules.py +++ b/filebeat/tests/system/test_modules.py @@ -106,6 +106,8 @@ def run_on_file(self, module, fileset, test_file, cfgfile): "-M", "{module}.*.enabled=false".format(module=module), "-M", "{module}.{fileset}.enabled=true".format( module=module, fileset=fileset), + "-M", "{module}.{fileset}.var.input=file".format( + module=module, fileset=fileset), "-M", "{module}.{fileset}.var.paths=[{test_file}]".format( module=module, fileset=fileset, test_file=test_file), "-M", "*.*.input.close_eof=true",