Skip to content

Commit

Permalink
Merge pull request #71 from andsel/fix/update_spec_synthax_to_jruby_9.4
Browse files Browse the repository at this point in the history
Fix dictionary definition passed into the spec methods
  • Loading branch information
andsel authored Jun 6, 2023
2 parents 7867dc8 + 03e47a0 commit 1533188
Showing 1 changed file with 17 additions and 17 deletions.
34 changes: 17 additions & 17 deletions spec/filters/dns_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
}
CONFIG

sample("foo" => "199.192.228.250") do
sample({"foo" => "199.192.228.250"}) do
insist { subject.get("foo") } == "carrera.databits.net"
end
end
Expand Down Expand Up @@ -68,7 +68,7 @@
}
CONFIG

sample("foo" => "199.192.228.250") do
sample({"foo" => "199.192.228.250"}) do
insist { subject.get("foo")[0] } == "199.192.228.250"
insist { subject.get("foo")[1] } == "carrera.databits.net"
end
Expand Down Expand Up @@ -104,7 +104,7 @@
}
CONFIG

sample("foo" => "not.an.ip") do
sample({"foo" => "not.an.ip"}) do
insist { subject.get("foo") } == "not.an.ip"
end
end
Expand All @@ -120,7 +120,7 @@
}
CONFIG

sample("host" => "carrera.databits.net") do
sample({"host" => "carrera.databits.net"}) do
insist { subject.get("host") } == "199.192.228.250"
insist { subject.get("tags") } == ["success"]
end
Expand Down Expand Up @@ -158,7 +158,7 @@
}
CONFIG

sample("host1" => "carrera.databits.net", "host2" => "nonexistanthostname###.net") do
sample({"host1" => "carrera.databits.net", "host2" => "nonexistanthostname###.net"}) do
insist { subject.get("tags") }.nil?
insist { subject.get("host1") } == "199.192.228.250"
insist { subject.get("host2") } == "nonexistanthostname###.net"
Expand All @@ -176,7 +176,7 @@
}
CONFIG

sample("host1" => "carrera.databits.net", "host2" => "carrera.databits.net") do
sample({"host1" => "carrera.databits.net", "host2" => "carrera.databits.net"}) do
insist { subject.get("tags") } == ["success"]
end
end
Expand All @@ -193,9 +193,9 @@
}
CONFIG

sample("host1" => "carrera.databits.net",
sample({"host1" => "carrera.databits.net",
"ip1" => "127.0.0.1",
"ip2" => "128.0.0.1") do
"ip2" => "128.0.0.1"}) do
insist { subject.get("tags") }.nil?
insist { subject.get("host1") } == "199.192.228.250"
insist { subject.get("ip1") } == "localhost"
Expand All @@ -213,7 +213,7 @@
}
CONFIG

sample("foo" => "carrera.databits.net") do
sample({"foo" => "carrera.databits.net"}) do
insist { subject.get("foo") } == "199.192.228.250"
end
end
Expand All @@ -228,7 +228,7 @@
}
CONFIG

sample("foo" => ["carrera.databits.net", "foo.databits.net"]) do
sample({"foo" => ["carrera.databits.net", "foo.databits.net"]}) do
insist { subject.get("foo") } == ["carrera.databits.net", "foo.databits.net"]
end
end
Expand All @@ -243,7 +243,7 @@
}
CONFIG

sample("foo" => { "hostname" => "carrera.databits.net" }) do
sample({"foo" => { "hostname" => "carrera.databits.net" }}) do
insist { subject.get("foo") } == { "hostname" => "carrera.databits.net" }
end
end
Expand All @@ -258,7 +258,7 @@
}
CONFIG

sample("foo" => "carrera.databits.net") do
sample({"foo" => "carrera.databits.net"}) do
insist { subject.get("foo")[0] } == "carrera.databits.net"
insist { subject.get("foo")[1] } == "199.192.228.250"
end
Expand All @@ -274,7 +274,7 @@
}
CONFIG

sample("foo" => ["carrera.databits.net", "foo.databits.net"]) do
sample({"foo" => ["carrera.databits.net", "foo.databits.net"]}) do
insist { subject.get("foo") } == ["carrera.databits.net", "foo.databits.net"]
end
end
Expand All @@ -288,7 +288,7 @@
}
CONFIG

sample("foo" => "does.not.exist") do
sample({"foo" => "does.not.exist"}) do
insist { subject.get("foo") } == "does.not.exist"
end
end
Expand All @@ -304,7 +304,7 @@
}
CONFIG

sample("host" => "carrera.databits.net") do
sample({"host" => "carrera.databits.net"}) do
insist { subject.get("host") } == "199.192.228.250"
end
end
Expand All @@ -320,7 +320,7 @@
}
CONFIG

sample("host" => "carrera.databits.net") do
sample({"host" => "carrera.databits.net"}) do
insist { subject.get("host") } == "199.192.228.250"
end
end
Expand All @@ -336,7 +336,7 @@
}
CONFIG

sample("host" => "carrera.databits.net") do
sample({"host" => "carrera.databits.net"}) do
insist { subject.get("host") } == "199.192.228.250"
end
end
Expand Down

0 comments on commit 1533188

Please sign in to comment.