Sha256: 5e59c24b081886d7ab5a8bf21e4f2f9ccd85b396f678594b0e66471ee73593e5

Contents?: true

Size: 655 Bytes

Versions: 3

Compression:

Stored size: 655 Bytes

Contents

module ConfigurableDaemonSettings
  extend ActiveSupport::Concern

  included do
    test "show form" do
      visit(__send__("daemon_setting_#{@type}_path"))
      assert do
        page.has_css?("input[name=\"setting[#{@form_name}]\"]")
      end
    end

    test "Update config" do
      assert do
        !@daemon.agent.config.include?(@form_value)
      end
      visit(__send__("daemon_setting_#{@type}_path"))
      within("form") do
        fill_in(@form_name.humanize, with: @form_value)
      end
      click_button(I18n.t("fluentd.common.finish"))
      assert do
        @daemon.agent.config.include?(@form_value)
      end
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
fluentd-ui-1.2.1 test/support/configurable_daemon_settings.rb
fluentd-ui-1.2.0 test/support/configurable_daemon_settings.rb
fluentd-ui-1.1.0 test/support/configurable_daemon_settings.rb