Closed dmcassel closed 7 years ago
Fixed code:
var test = require('/test/test-helper.xqy');
var simple = require('/lib/simple.sjs');
function addOnePlusOne() {
var actual = simple.addOne(1);
return [
test.assertEqual(2, actual),
test.assertNotEqual(5, actual)
];
};
function addOnePlusTwo() {
var actual = simple.addOne(2);
return test.assertEqual(3, actual);
};
[].concat(
addOnePlusOne(),
addOnePlusTwo()
)
https://github.com/marklogic-community/roxy/wiki/Unit-Testing#testing-server-side-javascript-with-server-side-javascript
The example shown looks like:
That won't return the asserts from addOnePlusOne.