add test
add test
add checking allocated memory