Left: | ||
Right: |
OLD | NEW |
---|---|
1 import os | 1 import os |
2 import sys | 2 import sys |
3 import time | 3 import time |
4 import runpy | 4 import runpy |
5 import signal | 5 import signal |
6 import pytest | 6 import pytest |
7 import urllib2 | 7 import urllib2 |
8 import subprocess | 8 import subprocess |
9 from conftest import ROOTPATH | 9 from conftest import ROOTPATH |
10 | 10 |
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
63 def test_static(output_pages, filename, expected_output): | 63 def test_static(output_pages, filename, expected_output): |
64 assert output_pages[filename] == expected_output | 64 assert output_pages[filename] == expected_output |
65 | 65 |
66 | 66 |
67 @pytest.mark.parametrize('filename,expected_output', expected_outputs) | 67 @pytest.mark.parametrize('filename,expected_output', expected_outputs) |
68 def test_dynamic(dynamic_server, filename, expected_output): | 68 def test_dynamic(dynamic_server, filename, expected_output): |
69 response = urllib2.urlopen(dynamic_server + filename) | 69 response = urllib2.urlopen(dynamic_server + filename) |
70 assert response.read() == expected_output | 70 assert response.read() == expected_output |
71 | 71 |
72 | 72 |
73 def test_revision_arg(revision, output_pages): | 73 def test_revision_arg(revision, temp_site): |
Vasily Kuznetsov
2017/06/23 14:15:24
Is this test related to `get_pages_metadata` globa
Jon Sonesen
2017/06/26 07:22:43
Yeah, so I actually shouldn't have changed this. D
| |
74 exists = os.path.isfile(os.path.join(temp_site, 'templates', 'bar.md')) | |
74 if revision is None: | 75 if revision is None: |
75 assert 'bar' in output_pages | 76 assert exists |
76 else: | 77 elif revision is 'test': |
77 assert 'bar' not in output_pages | 78 assert not exists |
OLD | NEW |