fixed test for negative input