1
0
Fork 0
mirror of https://github.com/middleman/middleman.git synced 2022-11-09 12:20:27 -05:00

New (failing) feature describing what it would look like to set some page features through frontmatter.

This tests the ability to set layout, ignore, and diable directory_index. Pertains to issue #194.
This commit is contained in:
Ben Hollis 2012-01-06 23:03:08 -08:00
parent 8de087ec65
commit b01f0f96e8
6 changed files with 32 additions and 0 deletions

View file

@ -0,0 +1,10 @@
Feature: Setting page settings through frontmatter
Scenario: Setting layout, ignoring, and disabling directory indexes through frontmatter
Given a successfully built app at "frontmatter-settings-app"
Then the following files should exist:
| build/proxied/index.html |
| build/no_index.html |
And the file "build/alternate_layout/index.html" should contain "Alternate layout"
And the following files should not exist:
| build/ignored/index.html |
| build/no_index/index.html |

View file

@ -0,0 +1,4 @@
activate :directory_indexes
# Proxy ignored.html, which should ignore itself through a frontmatter
page 'proxied.html', :proxy => 'ignored.html'

View file

@ -0,0 +1,3 @@
Alternate layout!
<%= yield %>

View file

@ -0,0 +1,5 @@
---
layout: alternate
---
This uses an alternate layout

View file

@ -0,0 +1,5 @@
---
ignored: true
---
This file ignores itself! But it can still be proxied.

View file

@ -0,0 +1,5 @@
---
directory_index: false
---
This should not be put in no_index/index.html - it goes to no_index.html