jsverify-contrib
v1.1.0
Published
Bells and whistles for jsverify
Downloads
11
Maintainers
Readme
jsverify-contrib
Property based checking. Like QuickCheck. Contrib modules.
Synopsis
var jsc = require("jsverify-contrib");
var jscSet = require("jsverify-contrib/set");
var jscDRange = require("jsverify-contrib/drange");
...
Set
Arbitrary for sets represented by an array, i.e. arrays without duplicates.
var setArb = require("jsverify-contrib/set");
Discontinuous Range
Selecting numbers uniformly from multiple ranges
var fromDiscontinuousRangeArb = require("jsverify-contrib/drange").fromDiscontinuousRange;
In the following example d
will generate 0, 1, 4, or 5.
var includedRanges = [{low: 0, high: 5}];
var excludeRanges = [{low: 2, high: 3}];
var d = fromDiscontinuousRangeArb(includedRanges, excludedRanges);
Contributing
README.md
is generated from the source with ljs- Before creating a pull request, run
make test
, yet travis will do it for you.
Release History
- 1.1.0 — 2015-09-11 — Discontinuos range number generation
- 1.0.1 — 2015-08-24 — Bump dependencies version
- 1.0.0 — 2015-08-21 — Initial release
The MIT License (MIT)
Copyright (c) 2015 Oleg Grenrus and jsverify-contrib contributors
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.