Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
Better namings for unit test cases.
  • Loading branch information
mashhurs authored Apr 1, 2024
1 parent 7dde084 commit 4678c4b
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@

describe "exclude config comments" do

it "doesn't exclude comments if config string dosn't contain ${VAR}" do
it "uses as it is if config string doesn't contain ${VAR}" do
single_line_config = "{ sleep { time => 1 } }"
multiline_config = "stdout {
codec => rubydebug
Expand All @@ -46,7 +46,7 @@
expect(substitution_var_test_class.exclude_config_comments(multiline_config)).to eq(multiline_config)
end

it "removes the line value if commented" do
it "removes the config line if commented" do
config_with_commented_var_line = 'tcp {
port => 12345
#"${TCP_PORT}"
Expand All @@ -55,7 +55,7 @@
.to eq("tcp {\nport => 12345\n}")
end

it "wipes out comments if config string contains ${VAR}" do
it "wipes out comments if ${VAR} is in the comment of the config string" do
config_with_var_and_comment = 'elasticsearch {
hosts => ["${ES_DEV_HOST}"] # use ["${ES_PROD_HOST}"] for production
index => "%{[some_field][sub_field]}-%{+YYYY.MM.dd}"
Expand Down

0 comments on commit 4678c4b

Please sign in to comment.