From: Vladimír Vondruš Date: Mon, 11 Dec 2017 01:39:52 +0000 (+0100) Subject: m.filesize: initial test. X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~cjwatson/git?a=commitdiff_plain;h=f1f2081ca714199067c7df3a033f293b4dac952f;p=blog.git m.filesize: initial test. --- diff --git a/pelican-plugins/m/test/filesize/page.html b/pelican-plugins/m/test/filesize/page.html new file mode 100644 index 00000000..d5564c4c --- /dev/null +++ b/pelican-plugins/m/test/filesize/page.html @@ -0,0 +1,42 @@ + + + + + m.filesize | A Pelican Blog + + + + + + + + + + + + + +
+
+
+
+
+
+

m.filesize

+ +

This file has 132.0 B and 106.0 B +gzipped.

+ +
+
+
+
+
+ + diff --git a/pelican-plugins/m/test/filesize/page.rst b/pelican-plugins/m/test/filesize/page.rst new file mode 100644 index 00000000..18d748a2 --- /dev/null +++ b/pelican-plugins/m/test/filesize/page.rst @@ -0,0 +1,7 @@ +m.filesize +########## + +:summary: no. + +This file has :filesize:`{filename}/page.rst` and :filesize-gz:`{filename}/page.rst` +gzipped. diff --git a/pelican-plugins/m/test/test_filesize.py b/pelican-plugins/m/test/test_filesize.py new file mode 100644 index 00000000..496788b6 --- /dev/null +++ b/pelican-plugins/m/test/test_filesize.py @@ -0,0 +1,12 @@ +from m.test import PluginTestCase + +class Filesize(PluginTestCase): + def __init__(self, *args, **kwargs): + super().__init__(__file__, '', *args, **kwargs) + + def test(self): + self.run_pelican({ + 'PLUGINS': ['m.htmlsanity', 'm.filesize'] + }) + + self.assertEqual(*self.actual_expected_contents('page.html'))