ENH: optimize: curve_fit now warns if pcov is undetermined

the test does not work in nosetest, but works when run manually. I left it in there because I think the test should be run, but Ralf and me could not understand why it fails under nosetest. Maybe add it as a KnownFail?