Fixed bug
Updated test