improve functionality tests