We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
math.copysign
1 parent e709f9f commit a351bd5Copy full SHA for a351bd5
integration_tests/test_math.py
@@ -84,6 +84,18 @@ def test_lcm():
84
assert i == 84
85
86
87
+def test_copysign():
88
+ f: f64
89
+ f = copysign(4, -1)
90
+ assert f == -4.0
91
+ f = copysign(-8, 97.21)
92
+ assert f == 8.0
93
+ f = copysign(0, -1)
94
+ assert f == -0.0
95
+ f = copysign(-43, -76)
96
+ assert f == -43.0
97
+
98
99
test_factorial_1()
100
test_comb()
101
test_isqrt()
@@ -96,3 +108,4 @@ def test_lcm():
108
test_ldexp()
109
test_gcd()
110
test_lcm()
111
+test_copysign()
0 commit comments