mirror of
https://github.com/revarbat/BOSL2.git
synced 2025-08-29 22:19:53 +02:00
doc tweaks for skin
bug fixes for is_matrix, is_vector, and new tests for same
This commit is contained in:
@@ -83,6 +83,12 @@ module test_is_matrix() {
|
||||
assert(!is_matrix([[2,3,4],[5,6,7]],n=5));
|
||||
assert(!is_matrix([[2,3],[5,6],[8,9]],m=2,n=3));
|
||||
assert(!is_matrix([[2,3,4],[5,6,7]],m=3,n=2));
|
||||
assert(!is_matrix([ [2,[3,4]],
|
||||
[4,[5,6]]]));
|
||||
assert(!is_matrix([[3,4],[undef,3]]));
|
||||
assert(!is_matrix([[3,4],[3,"foo"]]));
|
||||
assert(!is_matrix([[3,4],[3,3,2]]));
|
||||
assert(!is_matrix([ [3,4],6]));
|
||||
assert(!is_matrix(undef));
|
||||
assert(!is_matrix(NAN));
|
||||
assert(!is_matrix(INF));
|
||||
|
@@ -11,6 +11,10 @@ module test_is_vector() {
|
||||
assert(is_vector(1) == false);
|
||||
assert(is_vector("foo") == false);
|
||||
assert(is_vector(true) == false);
|
||||
assert(is_vector([3,4,"foo"]) == false);
|
||||
assert(is_vector([3,4,[4,5]]) == false);
|
||||
assert(is_vector([3,4,undef]) == false);
|
||||
assert(is_vector(["foo","bar"]) == false);
|
||||
|
||||
assert(is_vector([0,0,0],zero=true) == true);
|
||||
assert(is_vector([0,0,0],zero=false) == false);
|
||||
|
Reference in New Issue
Block a user