Say I've the following:
var using = require( 'typester' ).using;
function Thing( name, number ) {
using( arguments )
.verify( 'number' ).fulfills( Number );
}
Should this always fail because I'm not also checking the name argument which is part of arguments?
In this scenario I'm seeing an error stating that the number isn't fulfilling Number. When I think it should actually be saying something like All arguments weren't checked.
If I instead do:
var using = require( 'typester' ).using;
function Thing( name, number ) {
using( arguments )
.verify( 'name' ).fulfills( String );
}
I get the following error:
ArgumentError: only 1 argument(s) verified but 2 were provided
Which is much more informative. Maybe just some sorting check problem?