-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Bring in the sample site and setup an integration test
- Loading branch information
Showing
100 changed files
with
13,165 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
testsite/cache/ | ||
testsite/.doit.db.db | ||
testsite/.doit.db | ||
testsite/output | ||
testsite/plugins/__init__.py |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
# -*- coding: utf-8 -*- | ||
""" | ||
Testing the entire rendering process. | ||
""" | ||
from __future__ import absolute_import | ||
from __future__ import division | ||
from __future__ import print_function | ||
|
||
|
||
# disable: accessing protected members, too many methods | ||
# pylint: disable=W0212,R0904 | ||
|
||
import unittest | ||
|
||
from zope.testing.cleanup import CleanUp | ||
|
||
class TestRender(CleanUp,unittest.TestCase): | ||
|
||
def test_render(self): | ||
from nikola.__main__ import main | ||
import os | ||
import shutil | ||
cwd = os.getcwd() | ||
testsite = os.path.join(os.path.dirname(__file__), 'testsite') | ||
os.chdir(testsite) | ||
self.addCleanup(os.chdir, cwd) | ||
|
||
main(['build', '-q']) | ||
|
||
shutil.rmtree('output') | ||
# This gets different names under different versions | ||
# of python, for some reason. | ||
if os.path.exists('.doit.db.db'): # python 3 | ||
os.remove('.doit.db.db') | ||
else: | ||
os.remove(".doit.db") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
This folder contains the source used to generate a static site using Nikola. | ||
|
||
Installation and documentation at https://getnikola.com/ | ||
|
||
Configuration file for the site is ``conf.py``. | ||
|
||
To build the site:: | ||
|
||
nikola build | ||
|
||
To see it:: | ||
|
||
nikola serve -b | ||
|
||
To check all available commands:: | ||
|
||
nikola help |
Oops, something went wrong.