Feature: Collections As a hacker who likes to structure content I want to be able to create collections of similar information And render them Scenario: Unrendered collection Given I have an "index.html" page that contains "Collections: {{ site.methods }}" And I have fixture collections And I have a configuration file with "collections" set to "['methods']" When I run jekyll build Then the _site directory should exist And I should see "Collections:
Use Jekyll.configuration
to build a full configuration for use w/Jekyll.
Whatever: foo.bar
\nJekyll.sanitized_path
is used to make sure your path is in your source.
Run your generators! default
\nCreate dat site.
\nRun your generators! default
" in "_site/index.html" And the "_site/methods/configuration.html" file should not exist Scenario: Rendered collection Given I have an "index.html" page that contains "Collections: {{ site.collections }}" And I have an "collection_metadata.html" page that contains "Methods metadata: {{ site.collections.methods.foo }} {{ site.collections.methods }}" And I have fixture collections And I have a "_config.yml" file with content: """ collections: methods: output: true foo: bar """ When I run jekyll build Then the _site directory should exist And I should see "Collections: {\"methods" in "_site/index.html" And I should see "Methods metadata: bar" in "_site/collection_metadata.html" And I should see "Whatever: foo.bar
" in "_site/methods/configuration.html" Scenario: Rendered document in a layout Given I have an "index.html" page that contains "Collections: {{ site.collections }}" And I have a default layout that contains "Run your generators! default
" in "_site/methods/site/generate.html" And I should see "