Sha256: 74df9dcb87d36023649276d554b825d2dace359c94b0c2b62850a31f938be77a

Contents?: true

Size: 334 Bytes

Versions: 9

Compression:

Stored size: 334 Bytes

Contents

FactoryGirl.define do
  factory :column, class: "TableCloth::Column" do
    name :name
    options({})

    factory :if_column do
      name :name
      options({ if: :admin? })
    end

    factory :unless_column do
      name :name
      options({ unless: :moderator? })
    end

    initialize_with { new(name, options) }
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
table_cloth-0.4.3 spec/factories/columns.rb
table_cloth-0.4.2 spec/factories/columns.rb
table_cloth-0.4.1 spec/factories/columns.rb
table_cloth-0.4.0 spec/factories/columns.rb
table_cloth-0.3.2 spec/factories/columns.rb
table_cloth-0.3.1.alpha1 spec/factories/columns.rb
table_cloth-0.3.0.beta3 spec/factories/columns.rb
table_cloth-0.3.0.beta2 spec/factories/columns.rb
table_cloth-0.3.0.beta1 spec/factories/columns.rb