Mercurial > piecrust2
diff tests/test_sources_autoconfig.py @ 267:f512905ae812
sources: Generate proper slugs in the `autoconfig` and `ordered` sources.
author | Ludovic Chabant <ludovic@chabant.com> |
---|---|
date | Wed, 25 Feb 2015 13:06:41 -0800 |
parents | f130365568ff |
children | a2d283d1033d |
line wrap: on
line diff
--- a/tests/test_sources_autoconfig.py Wed Feb 25 08:31:30 2015 -0800 +++ b/tests/test_sources_autoconfig.py Wed Feb 25 13:06:41 2015 -0800 @@ -7,6 +7,10 @@ 'fs, src_config, expected_paths, expected_metadata', [ (mock_fs(), {}, [], []), + (mock_fs().withPage('test/_index.md'), + {}, + ['_index.md'], + [{'slug': '', 'config': {'foo': []}}]), (mock_fs().withPage('test/something.md'), {}, ['something.md'], @@ -86,6 +90,10 @@ 'fs, expected_paths, expected_metadata', [ (mock_fs(), [], []), + (mock_fs().withPage('test/_index.md'), + ['_index.md'], + [{'slug': '', + 'config': {'foo': 0, 'foo_trail': [0]}}]), (mock_fs().withPage('test/something.md'), ['something.md'], [{'slug': 'something',