changeset 4950:3be35ace8aca

test_conv160*: overwriting of i18n.wikiLanguages reverted for tests
author Reimar Bauer <rb.proj AT googlemail DOT com>
date Wed, 19 Aug 2009 23:06:40 +0200
parents b1bfe9bc5375
children 043baa5879b3 11ce9cde8f85
files MoinMoin/script/migration/_tests/test_conv160_wiki.py MoinMoin/script/migration/_tests/test_conv160a_wiki.py
diffstat 2 files changed, 9 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/MoinMoin/script/migration/_tests/test_conv160_wiki.py	Wed Aug 19 22:45:52 2009 +0200
+++ b/MoinMoin/script/migration/_tests/test_conv160_wiki.py	Wed Aug 19 23:06:40 2009 +0200
@@ -21,7 +21,11 @@
 import py
 #py.test.skip("broken")
 
+from MoinMoin import i18n
+i18n_wikiLanguages = i18n.wikiLanguages
+# convert_wiki overwrites i18n.wikiLanguages, we revert this change for following tests
 from MoinMoin.script.migration._conv160_wiki import convert_wiki
+i18n.wikiLanguages = i18n_wikiLanguages
 
 class TestWikiConversion:
     """ test the wiki markup conversion 1.5.8 -> 1.6.0 """
@@ -111,7 +115,7 @@
             # macros
             ('[[BR]]', {}, '<<BR>>'),
             ('[[FullSearch(wtf)]]', {}, '<<FullSearch(wtf)>>'),
-            (u'[[ImageLink(tst.png)]]', {}, u'[[attachment:tst.png|{{attachment:tst.png}}]]'),
+            (u'[[ImageLink(t�st.png)]]', {}, u'[[attachment:t�st.png|{{attachment:t�st.png}}]]'),
             ('[[ImageLink(test.png,OtherPage)]]', {}, '[[OtherPage|{{attachment:test.png}}]]'),
             ('[[ImageLink(test.png,OtherPage,width=123,height=456)]]', {}, '[[OtherPage|{{attachment:test.png||width=123, height=456}}]]'),
             ('[[ImageLink(test.png,OtherPage,width=123,height=456,alt=alttext)]]', {}, '[[OtherPage|{{attachment:test.png|alttext|width=123, height=456}}]]'),
--- a/MoinMoin/script/migration/_tests/test_conv160a_wiki.py	Wed Aug 19 22:45:52 2009 +0200
+++ b/MoinMoin/script/migration/_tests/test_conv160a_wiki.py	Wed Aug 19 23:06:40 2009 +0200
@@ -20,7 +20,11 @@
 import py
 #py.test.skip("broken")
 
+from MoinMoin import i18n
+i18n_wikiLanguages = i18n.wikiLanguages
+# convert_wiki overwrites i18n.wikiLanguages, we revert this change for following tests
 from MoinMoin.script.migration._conv160a_wiki import convert_wiki
+i18n.wikiLanguages = i18n_wikiLanguages
 
 class TestWikiConversion:
     """ test the wiki markup conversion 1.6.0a -> 1.6.0 """