Sha256: 9b4611fecde38ce49013f50e15e430e864de08f0ad57c2a0a0abbc4a621e6a31

Contents?: true

Size: 433 Bytes

Versions: 7

Compression:

Stored size: 433 Bytes

Contents

# frozen_string_literal: true

FactoryBot.define do
  factory :template, class: "Archangel::Template" do
    site
    sequence(:name) { |n| "Template #{n} Name" }
    content <<-CONTENT
      <p>BEFORE TEMPLATE<p>
      <p>{{ content_for_layout }}<p>
      <p>AFTER TEMPLATE<p>
    CONTENT
    partial false

    trait :partial do
      partial true
    end

    trait :deleted do
      deleted_at { Time.current }
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
archangel-0.0.8 lib/archangel/testing_support/factories/archangel_templates.rb
archangel-0.0.7 lib/archangel/testing_support/factories/archangel_templates.rb
archangel-0.0.6 lib/archangel/testing_support/factories/archangel_templates.rb
archangel-0.0.5 lib/archangel/testing_support/factories/archangel_templates.rb
archangel-0.0.4 lib/archangel/testing_support/factories/archangel_templates.rb
archangel-0.0.3 lib/archangel/testing_support/factories/archangel_templates.rb
archangel-0.0.2 lib/archangel/testing_support/factories/archangel_templates.rb