1
0
mirror of https://github.com/JustinSDK/dotSCAD.git synced 2025-08-30 18:00:01 +02:00
This commit is contained in:
Justin Lin
2022-03-11 15:29:11 +08:00
parent 21c00b52d3
commit ffbb7c5db4
2 changed files with 15 additions and 1 deletions

View File

@@ -0,0 +1,13 @@
use <unittest.scad>;
use <util/spherical_coordinate.scad>;
module test_spherical_coordinate() {
echo("==== test_spherical_coordinate ====");
coord = spherical_coordinate([100, 100, 100]);
r = round(coord[0]);
theta = round(coord[1]);
phi = round(coord[2]);
assert([r, theta, phi] == [173, 45, 55]);
}
test_spherical_coordinate();