diff tests/test_data_linker.py @ 979:45ad976712ec

tests: Big push to get the tests to pass again. - Lots of fixes everywhere in the code. - Try to handle debug logging in the multiprocessing worker pool when running in pytest. Not perfect, but usable for now. - Replace all `.md` test files with `.html` since now a auto-format extension always sets the format. - Replace `out` with `outfiles` in most places since now blog archives are added to the bake output and I don't want to add expected outputs for blog archives everywhere.
author Ludovic Chabant <ludovic@chabant.com>
date Sun, 29 Oct 2017 22:51:57 -0700
parents 72f17534d58e
children
line wrap: on
line diff
--- a/tests/test_data_linker.py	Sun Oct 29 22:46:41 2017 -0700
+++ b/tests/test_data_linker.py	Sun Oct 29 22:51:57 2017 -0700
@@ -7,12 +7,12 @@
     'fs_fac, page_path, expected',
     [
         (lambda: mock_fs().withPage('pages/foo'), 'foo',
-         []),
+         ['/foo']),
         ((lambda: mock_fs()
           .withPage('pages/foo')
           .withPage('pages/bar')),
          'foo',
-         ['/bar']),
+         ['/bar', '/foo']),
         ((lambda: mock_fs()
           .withPage('pages/baz')
           .withPage('pages/something')
@@ -20,14 +20,14 @@
           .withPage('pages/foo')
           .withPage('pages/bar')),
          'foo',
-         ['/bar', '/baz', '/something']),
+         ['/bar', '/baz', '/foo', '/something']),
         ((lambda: mock_fs()
           .withPage('pages/something/else')
           .withPage('pages/foo')
           .withPage('pages/something/good')
           .withPage('pages/bar')),
          'something/else',
-         ['/something/good'])
+         ['/something/else', '/something/good'])
     ])
 def test_linker_siblings(fs_fac, page_path, expected):
     fs = fs_fac()