Sha256: e1f03d20b22618527378713317701443b623da4ad1e80585700aea14addb30e7

Contents?: true

Size: 362 Bytes

Versions: 158

Compression:

Stored size: 362 Bytes

Contents

# frozen_string_literal: true

module SelectDateSpecHelper
  def select_date(date, options = {})
    field = options[:from]
    base_id = find(:xpath, ".//label[contains(.,'#{field}')]")[:for]
    year, month, day = date.split(",")
    select year,  from: "#{base_id}_1i"
    select month, from: "#{base_id}_2i"
    select day,   from: "#{base_id}_3i"
  end
end

Version data entries

158 entries across 158 versions & 1 rubygems

Version Path
renalware-core-2.1.1 spec/support/select_date_spec_helper.rb
renalware-core-2.1.0 spec/support/select_date_spec_helper.rb
renalware-core-2.0.167 spec/support/select_date_spec_helper.rb
renalware-core-2.0.166 spec/support/select_date_spec_helper.rb
renalware-core-2.0.165 spec/support/select_date_spec_helper.rb
renalware-core-2.0.164 spec/support/select_date_spec_helper.rb
renalware-core-2.0.163 spec/support/select_date_spec_helper.rb
renalware-core-2.0.162 spec/support/select_date_spec_helper.rb
renalware-core-2.0.161 spec/support/select_date_spec_helper.rb
renalware-core-2.0.160 spec/support/select_date_spec_helper.rb
renalware-core-2.0.159 spec/support/select_date_spec_helper.rb
renalware-core-2.0.158 spec/support/select_date_spec_helper.rb
renalware-core-2.0.157 spec/support/select_date_spec_helper.rb
renalware-core-2.0.156 spec/support/select_date_spec_helper.rb
renalware-core-2.0.155 spec/support/select_date_spec_helper.rb
renalware-core-2.0.153 spec/support/select_date_spec_helper.rb
renalware-core-2.0.152 spec/support/select_date_spec_helper.rb
renalware-core-2.0.151 spec/support/select_date_spec_helper.rb
renalware-core-2.0.149 spec/support/select_date_spec_helper.rb
renalware-core-2.0.148 spec/support/select_date_spec_helper.rb