fixed needle tests for function needles branch