Sha256: f30d17f912ec3adbf518a2fde5856b0fb443a9fe0261f47fbfddb8305ab20d6f

Contents?: true

Size: 464 Bytes

Versions: 3

Compression:

Stored size: 464 Bytes

Contents

Factory.define :structure_page, :class => Structure do |s|
  s.title 'Structure'
  s.slug { Factory.next(:slug) }
  s.structure_type StructureType.page
  s.position_type PositionType.menu
  s.is_visible true
end

Factory.define :structure_main, :class => Structure do |s|
  s.title "Main page"
  s.slug "main-page"
  s.structure_type StructureType.main
  s.position_type PositionType.default
  s.is_visible true
end

Factory.sequence :slug do |n|
  "slug#{n}"
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
sunrise-core-0.2.2 spec/factories/structure_factory.rb
sunrise-core-0.2.1 spec/factories/structure_factory.rb
sunrise-core-0.2.0 spec/factories/structure_factory.rb