Skip to content

Commit

Permalink
fix test for missing log level
Browse files Browse the repository at this point in the history
  • Loading branch information
yaron-idan committed Jul 3, 2019
1 parent 7dd6608 commit 8c48355
Showing 1 changed file with 2 additions and 9 deletions.
11 changes: 2 additions & 9 deletions test/plugin/test_filter_kubernetes_log_level.rb
Original file line number Diff line number Diff line change
Expand Up @@ -74,14 +74,7 @@ class KubernetesLogLevelFilterTest < Test::Unit::TestCase
}
}]

@missing_log_level_key = [{
'kubernetes' => {
'labels' => {
'logging-level-key' => 'notexist',
'app' => 'demo'
}
}
}]
@missing_log_level_key = []

@expected_numeric = [{
'level' => 50,
Expand Down Expand Up @@ -170,7 +163,7 @@ def test_numeric_log_level
end

def test_missing_log_level
assert_equal [], filter({"level"=>30, "kubernetes"=>{"labels"=>{"app"=>"demo", "logging-level-key"=>"levelname", "logging-level"=>"Warning"}}})
assert_equal @missing_log_level_key, filter({"kubernetes"=>{"labels"=>{"app"=>"demo", "logging-level-key"=>"levelname", "logging-level"=>"Warning"}}})
end

def test_capitialize_log_level
Expand Down

0 comments on commit 8c48355

Please sign in to comment.