test/plugin/test_out_redis.rb in fluent-plugin-redis-0.2.1 vs test/plugin/test_out_redis.rb in fluent-plugin-redis-0.2.2
- old
+ new
@@ -19,9 +19,23 @@
def test_configure
assert_equal 'localhost', @d.instance.host
assert_equal 6379, @d.instance.port
assert_equal 1, @d.instance.db_number
+ assert_nil @d.instance.password
+ end
+
+ def test_configure_with_password
+ d = create_driver %[
+ host localhost
+ port 6379
+ db_number 1
+ password testpass
+ ]
+ assert_equal 'localhost', d.instance.host
+ assert_equal 6379, d.instance.port
+ assert_equal 1, d.instance.db_number
+ assert_equal 'testpass', d.instance.password
end
def test_format
@d.emit({"a"=>1}, @time)
@d.expect_format(["test.#{@time}", {"a"=>1}].to_msgpack)