Skip to content

Commit

Permalink
tests showing Issue getnikola#438
Browse files Browse the repository at this point in the history
  • Loading branch information
ralsina committed Apr 7, 2013
1 parent 40403c8 commit dc58e10
Showing 1 changed file with 32 additions and 0 deletions.
32 changes: 32 additions & 0 deletions tests/test_integration.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
import locale
import os
import shutil
import subprocess # NOQA
import tempfile
import unittest

Expand Down Expand Up @@ -151,6 +152,37 @@ def test_relative_links(self):
self.assertTrue(flag)


#class TestCheck(DemoBuildTest):
#"""The demo build should pass 'nikola check'"""

#def test_check_links(self):
#with cd(self.target_dir):
#r = subprocess.call("nikola check -l", shell=True)
#self.assertEqual(r, 0)

#def test_check_files(self):
#with cd(self.target_dir):
#r = subprocess.call("nikola check -f", shell=True)
#self.assertEqual(r, 0)


#class TestCheckFailure(DemoBuildTest):
#"""The demo build should pass 'nikola check'"""

#def test_check_links_fail(self):
#with cd(self.target_dir):
#os.unlink(os.path.join("output", "archive.html"))
#rv = subprocess.call("nikola check -l", shell=True)
#self.assertEqual(rv, 1)

#def test_check_files_fail(self):
#with cd(self.target_dir):
#with codecs.open(os.path.join("output", "foobar"), "wb+", "utf8") as outf:
#outf.write("foo")
#rv = subprocess.call("nikola check -f", shell=True)
#self.assertEqual(rv, 1)


class RelativeLinkTest2(DemoBuildTest):
"""Check that dropping stories to the root doesn't break links."""

Expand Down

0 comments on commit dc58e10

Please sign in to comment.