summaryrefslogtreecommitdiff
path: root/librelogo
diff options
context:
space:
mode:
authorLászló Németh <nemeth@numbertext.org>2018-10-25 17:14:09 +0200
committerLászló Németh <nemeth@numbertext.org>2018-10-26 07:48:57 +0200
commit1b341e578083b492c620bd468e20f28f2039bfd8 (patch)
tree4d9475a764b629c6e1b3053f04beef6535425cc6 /librelogo
parent9f93ab871eb068574448b99569f89893b5c1ebdb (diff)
LibreLogo: add unit tests for program compilation
from LibreLogo to Python Change-Id: I39df100a13efe3573b33cb856701cbeb0d95954d Reviewed-on: https://gerrit.libreoffice.org/62364 Tested-by: Jenkins Reviewed-by: László Németh <nemeth@numbertext.org>
Diffstat (limited to 'librelogo')
-rw-r--r--librelogo/source/LibreLogo/LibreLogo.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/librelogo/source/LibreLogo/LibreLogo.py b/librelogo/source/LibreLogo/LibreLogo.py
index 0dc5d7ea2ed7..8834baf8e640 100644
--- a/librelogo/source/LibreLogo/LibreLogo.py
+++ b/librelogo/source/LibreLogo/LibreLogo.py
@@ -1735,6 +1735,9 @@ def __compil__(s):
__loadlang__(_.lng, __l12n__(_.lng))
except:
__trace__()
+ # for testing compiling, we create a not document based namespace
+ if "_" not in locals():
+ _ = lambda: None
_.lng = 'en_US'
if not _.lng in __comp__:
__loadlang__(_.lng, __l12n__(_.lng))