[issue27763] Add complex case to test_builtin abs()

2021-04-22 Thread Mark Dickinson
Change by Mark Dickinson : -- resolution: -> out of date ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue27763] Add complex case to test_builtin abs()

2021-04-22 Thread Mark Dickinson
Mark Dickinson added the comment: Yes, it looks as though we do have tests of the form that Evelyn describes in test_complex (which also seems like the right place for those tests). Closing here. Thanks Sergey for the ping! -- stage: test needed -> resolved status: open -> closed

[issue27763] Add complex case to test_builtin abs()

2021-04-21 Thread Sergey B Kirpichev
Sergey B Kirpichev added the comment: > We're testing the cmath functions on complex number inputs Indeed. Also, for abs(complex) - there is test_abs() in the test_complex.py. > The complex number creation from both strings and pairs of floats should be > tested independently, of course.

[issue27763] Add complex case to test_builtin abs()

2016-08-15 Thread Mark Dickinson
Mark Dickinson added the comment: > in looking through test_cmath, it appears that only the two numeric > argument form of complex(i, j) is tested for any of the functions, not the > complex('i+nj') string form. We're testing the cmath functions on complex number inputs; I don't think it

[issue27763] Add complex case to test_builtin abs()

2016-08-14 Thread Evelyn Mitchell
Evelyn Mitchell added the comment: test_cmath includes abs() of zeros, infinities, and real or imaginary part NaN, but does not include a test for the magnitude conversion, which would be triggered by something like >>> abs(complex(2.1,3.5)) 4.08166632639171 >>> abs(complex('2.1+3.5j'))

[issue27763] Add complex case to test_builtin abs()

2016-08-14 Thread Ned Deily
Ned Deily added the comment: I think tests for abs() using complex numbers are already in test_cmath. How do they look? -- nosy: +ned.deily ___ Python tracker

[issue27763] Add complex case to test_builtin abs()

2016-08-14 Thread Evelyn Mitchell
New submission from Evelyn Mitchell: The description of abs() says "If the argument is a complex number, its magnitude is returned." but test_builtin doesn't include any complex number test cases. -- components: Library (Lib) messages: 272688 nosy: Evelyn Mitchell priority: low