Skip to content

Commit

Permalink
the test is ridiculously wrong...
Browse files Browse the repository at this point in the history
  • Loading branch information
ralsina committed May 22, 2015
1 parent f2477e9 commit 161a69e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion nikola/plugins/command/import_wordpress.py
Expand Up @@ -335,7 +335,7 @@ def download_additional_image_sizes(self, item, wordpress_namespace, source_path
links[url] = '/' + dst_url
links[url] = '/' + dst_url

code_re = re.compile(r'\[(?:source)?code(?: lang(?:uage)?="(.*?)")?\](.*?)\[/code\]', re.DOTALL)
code_re = re.compile(r'\[(?:source)?code(?: lang(?:uage)?="(.*?)")?\](.*?)\[/code\]', re.DOTALL | re.MULTILINE)

def transform_code(self, content):
# http://en.support.wordpress.com/code/posting-source-code/. There are
Expand Down
4 changes: 2 additions & 2 deletions tests/test_command_import_wordpress.py
Expand Up @@ -332,12 +332,12 @@ def test_transforming_source_code(self):

replaced_content = """Hello World.
~~~~~~~~~~~~{.Python}
```Python
import sys
print sys.version
~~~~~~~~~~~~
```
"""

self.assertEqual(content, replaced_content)
Expand Down

0 comments on commit 161a69e

Please sign in to comment.