From 9fc1a82168fe7fb7a54c87abf09d7eec53ae2548 Mon Sep 17 00:00:00 2001 From: Maximiliano Kotvinsky Date: Thu, 19 Oct 2017 15:18:30 -0300 Subject: [PATCH] Backport add-test-for-layout-as-string from #6445 to 3.6-stable --- features/layout_data.feature | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/features/layout_data.feature b/features/layout_data.feature index c2af5b70ebe..8a10ce87f83 100644 --- a/features/layout_data.feature +++ b/features/layout_data.feature @@ -3,6 +3,26 @@ Feature: Layout data I want to be able to embed data into my layouts In order to make the layouts slightly dynamic + Scenario: Use custom layout data + Given I have a _layouts directory + And I have a "_layouts/999.html" file with content: + """ + --- + --- + {{ content }} layout content + """ + And I have an "index.html" page with layout "custom" that contains "page content" + And I have an "index.html" file with content: + """ + --- + layout: 999 + --- + page content + """ + When I run jekyll build + Then the "_site/index.html" file should exist + And I should see "page content layout content" in "_site/index.html" + Scenario: Use custom layout data Given I have a _layouts directory And I have a "_layouts/custom.html" file with content: