Skip to content

Commit

Permalink
Merge branch 'master' into load_rule_schema
Browse files Browse the repository at this point in the history
  • Loading branch information
jertel authored Nov 23, 2021
2 parents a3f561b + 2d9306d commit 0a9c36d
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions tests/loaders_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,9 @@
from elastalert.loaders import RulesLoader
from elastalert.util import EAException

test_config = {'rules_folder': './empty_folder_test',
empty_folder_test_path = os.path.join(os.path.dirname(__file__), 'empty_folder_test')

test_config = {'rules_folder': empty_folder_test_path,
'run_every': {'minutes': 10},
'buffer_time': {'minutes': 10},
'es_host': 'elasticsearch.test',
Expand Down Expand Up @@ -169,7 +171,7 @@ def test_load_inline_alert_rule():


def test_file_rules_loader_get_names_recursive():
conf = {'scan_subdirectories': True, 'rules_folder': './empty_folder_test'}
conf = {'scan_subdirectories': True, 'rules_folder': empty_folder_test_path}
rules_loader = FileRulesLoader(conf)
walk_paths = (('root', ['folder_a', 'folder_b'], ('rule.yaml',)),
('root/folder_a', [], ('a.yaml', 'ab.yaml')),
Expand Down

0 comments on commit 0a9c36d

Please sign in to comment.