-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Memory leak is not checked for luatest.server instance #349
Labels
feature
A new functionality
Comments
Maybe related: #252 |
ASAN build instructions:
Source this from tarantool dir (because of
|
ochaplashkin
pushed a commit
to ochaplashkin/luatest
that referenced
this issue
Mar 13, 2024
Unexpected errors may occur when working with the server: g.test_foo = function() ... g.server:exec(function() // there is an error in `stderr` here end) g.server:exec(function() // server is alive end) t.assert(true) end) g.after_all(function() g.server:drop() // `test_foo` has been passed end) We have added a check of the `stderr` from the server for the presence of the `ERROR` substring. If it is found, an error will be caused (test will be failed). Closes tarantool#349
This was referenced Mar 13, 2024
ochaplashkin
pushed a commit
to ochaplashkin/luatest
that referenced
this issue
Mar 14, 2024
Memory leak detection may occur when working with the server: g.test_foo = function() ... g.server:exec(function() // there is an error in `stderr` here end) g.server:exec(function() // server is alive end) t.assert(true) end) g.after_all(function() g.server:drop() // `test_foo` has been passed end) We have added a check of the `stderr` from the server for the presence of the `LeakSanitizer` substring. If it's found, an error will be caused (test will be failed). Closes tarantool#349
ochaplashkin
pushed a commit
to ochaplashkin/luatest
that referenced
this issue
Mar 14, 2024
Memory leak detection may occur when working with the server: g.test_foo = function() ... g.server:exec(function() // there is an error in `stderr` here end) g.server:exec(function() // server is alive end) t.assert(true) end) g.after_all(function() g.server:drop() // `test_foo` has been passed end) We have added a check of the `stderr` from the server for the presence of the `LeakSanitizer` substring. If it's found, an error will be caused (test will be failed). Closes tarantool#349
ochaplashkin
pushed a commit
to ochaplashkin/luatest
that referenced
this issue
Mar 14, 2024
Memory leak detection may occur when working with the server: g.test_foo = function() ... g.server:exec(function() // there is an error in `stderr` here end) g.server:exec(function() // server is alive end) t.assert(true) end) g.after_all(function() g.server:drop() // `test_foo` has been passed end) We have added a check of the `stderr` from the server for the presence of the `LeakSanitizer` substring. If it's found, an error will be caused (test will be failed). Closes tarantool#349
ochaplashkin
pushed a commit
to ochaplashkin/luatest
that referenced
this issue
Mar 14, 2024
Memory leak detection may occur when working with the server: g.test_foo = function() ... g.server:exec(function() -- there is an error in `stderr` here end) g.server:exec(function() -- server is alive end) t.assert(true) end) g.after_all(function() g.server:drop() -- `test_foo` has been passed end) We have added a check of the `stderr` from the server for the presence of the `LeakSanitizer` substring. If it's found, an error will be caused (test will be failed). Closes tarantool#349
ochaplashkin
pushed a commit
to ochaplashkin/luatest
that referenced
this issue
Mar 14, 2024
Memory leak detection may occur when working with the server: g.test_foo = function() ... g.server:exec(function() -- there is an error in `stderr` here end) g.server:exec(function() -- server is alive end) t.assert(true) end) g.after_all(function() g.server:drop() -- `test_foo` has been passed end) We have added a check of the `stderr` from the server for the presence of the `LeakSanitizer` substring. If it's found, an error will be caused (test will be failed). Closes tarantool#349
ochaplashkin
pushed a commit
to ochaplashkin/luatest
that referenced
this issue
Mar 19, 2024
Memory leak detection may occur when working with the server: g.test_foo = function() ... g.server:exec(function() -- there is an error from LeakSanitizer in `stderr` here end) g.server:exec(function() -- server is alive end) t.assert(true) end) g.after_all(function() g.server:drop() -- `test_foo` has passed end) We have added a check for the `LeakSanitizer` substring in `stderr` of the server process. If it's found, an error will be thrown and test will fail. Closes tarantool#349
ylobankov
pushed a commit
that referenced
this issue
Mar 19, 2024
Memory leak detection may occur when working with the server: g.test_foo = function() ... g.server:exec(function() -- there is an error from LeakSanitizer in `stderr` here end) g.server:exec(function() -- server is alive end) t.assert(true) end) g.after_all(function() g.server:drop() -- `test_foo` has passed end) We have added a check for the `LeakSanitizer` substring in `stderr` of the server process. If it's found, an error will be thrown and test will fail. Closes #349
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
In case of memory leak sanitized program exit with non zero exit code. But we do not check the exit code for
luatest.server
instance onserver:stop()
orserver:drop()
. As a result test will pass. In order to test for memory leaks we should fail in this case.Or may be we should fail if there is
ERROR: LeakSanitizer: detected memory leaks
in stderr output of the program.Changes for demo:
Test for leak detection on simple run:
Test for leak detection in luatest:
There is similar issue for
core = tarantool
tests tarantool/test-run#416.The text was updated successfully, but these errors were encountered: