summaryrefslogtreecommitdiff
path: root/Build/source/utils/asymptote/tests/arith/real.asy
blob: 1628258cf838079546610ca0b8c17828e75796e2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
// Real arithmetic.

import TestLib;
StartTest("real error");
assert((1.0-1.0) < realEpsilon);
EndTest();
StartTest("real addition");
assert((1.0+1.0) == (2.0));
EndTest();
StartTest("real subtraction");
assert((2.0-1.0) == (1.0));
EndTest();
StartTest("real multiplication");
assert((2.0*2.0) == (4.0));
EndTest();
StartTest("real division");
assert((4.0/2.0) == (2.0));
EndTest();