diff options
Diffstat (limited to 'testes')
| -rw-r--r-- | testes/main.lua | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/testes/main.lua b/testes/main.lua index 56959abd..52c77954 100644 --- a/testes/main.lua +++ b/testes/main.lua | |||
| @@ -190,6 +190,11 @@ prepfile(("print(a); print(_G['%s'].x)"):format(prog), otherprog) | |||
| 190 | RUN('env LUA_PATH="?;;" lua -l %s -l%s -lstring -l io %s > %s', prog, otherprog, otherprog, out) | 190 | RUN('env LUA_PATH="?;;" lua -l %s -l%s -lstring -l io %s > %s', prog, otherprog, otherprog, out) |
| 191 | checkout("1\n2\n15\n2\n15\n") | 191 | checkout("1\n2\n15\n2\n15\n") |
| 192 | 192 | ||
| 193 | -- test explicit global names in -l | ||
| 194 | prepfile("print(str.upper'alo alo', m.max(10, 20))") | ||
| 195 | RUN("lua -l 'str=string' '-lm=math' -e 'print(m.sin(0))' %s > %s", prog, out) | ||
| 196 | checkout("0.0\nALO ALO\t20\n") | ||
| 197 | |||
| 193 | -- test 'arg' table | 198 | -- test 'arg' table |
| 194 | local a = [[ | 199 | local a = [[ |
| 195 | assert(#arg == 3 and arg[1] == 'a' and | 200 | assert(#arg == 3 and arg[1] == 'a' and |
