Sha256: 842e47203872d0c142c25e890842be14a8e038d319a55d5edfb73b095c177d56

Contents?: true

Size: 396 Bytes

Versions: 8

Compression:

Stored size: 396 Bytes

Contents

# frozen_string_literal: true

require 'pathway/rspec/matchers/list_helpers'

module Pathway
  module Rspec
    module FieldListHelpers
      include ListHelpers

      def field_list
        as_list(@fields)
      end

      def were_was(list)
        list.size > 1 ? 'were' : 'was'
      end

      def pluralize_fields
        @fields.size > 1 ? 'fields' : 'field'
      end
    end
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
pathway-0.12.3 lib/pathway/rspec/matchers/field_list_helpers.rb
pathway-0.12.2 lib/pathway/rspec/matchers/field_list_helpers.rb
pathway-0.12.1 lib/pathway/rspec/matchers/field_list_helpers.rb
pathway-0.12.0 lib/pathway/rspec/matchers/field_list_helpers.rb
pathway-0.11.3 lib/pathway/rspec/matchers/field_list_helpers.rb
pathway-0.11.2 lib/pathway/rspec/matchers/field_list_helpers.rb
pathway-0.11.1 lib/pathway/rspec/matchers/field_list_helpers.rb
pathway-0.11.0 lib/pathway/rspec/matchers/field_list_helpers.rb