[Tarantool-patches] [PATCH luajit 19/36] test: enable <misc/parse_comp.lua> LuaJIT test
Sergey Kaplun
skaplun at tarantool.org
Wed Aug 14 16:56:01 MSK 2024
This patch moves the aforementioned test from the <misc> to the <lang/>
directory, includes it in <index>, and names the subtests.
Part of tarantool/tarantool#9398
---
test/LuaJIT-tests/lang/index | 1 +
test/LuaJIT-tests/lang/parse_comp.lua | 12 ++++++++++++
test/LuaJIT-tests/misc/parse_comp.lua | 13 -------------
3 files changed, 13 insertions(+), 13 deletions(-)
create mode 100644 test/LuaJIT-tests/lang/parse_comp.lua
delete mode 100644 test/LuaJIT-tests/misc/parse_comp.lua
diff --git a/test/LuaJIT-tests/lang/index b/test/LuaJIT-tests/lang/index
index 327b40fe..371a5768 100644
--- a/test/LuaJIT-tests/lang/index
+++ b/test/LuaJIT-tests/lang/index
@@ -17,6 +17,7 @@ modulo.lua
concat.lua
self.lua
table.lua
+parse_comp.lua
upvalue
tail_recursion.lua
vararg_jit.lua
diff --git a/test/LuaJIT-tests/lang/parse_comp.lua b/test/LuaJIT-tests/lang/parse_comp.lua
new file mode 100644
index 00000000..ee6a74de
--- /dev/null
+++ b/test/LuaJIT-tests/lang/parse_comp.lua
@@ -0,0 +1,12 @@
+do --- Parse inline comparisions expressions, base.
+ local f = {{n = 5}}
+ local a = f[1].n
+ assert(1 < a)
+ assert(1 < (f[1].n))
+ assert(1 < f[1].n)
+end
+
+do --- Parse inline comparisions expressions with not.
+ local tt = { a = 1 }
+ assert(not(0 >= tt.a))
+end
diff --git a/test/LuaJIT-tests/misc/parse_comp.lua b/test/LuaJIT-tests/misc/parse_comp.lua
deleted file mode 100644
index 5e1948da..00000000
--- a/test/LuaJIT-tests/misc/parse_comp.lua
+++ /dev/null
@@ -1,13 +0,0 @@
-
-do
- local f = {{n=5}}
- local a = f[1].n
- assert(1 < a)
- assert(1 < (f[1].n))
- assert(1 < f[1].n)
-end
-
-do
- tt = { a = 1 }
- assert(not(0 >= tt.a))
-end
--
2.45.2
More information about the Tarantool-patches
mailing list