There should be an ability to compare performance of certain scenarios (not versus KnockoutJS)
For example I know at least 2 tests I want to write that way.
Example 1
Given the following definitions:
var x = [];
for (var j = 0; j < dependenciesCount; j++) {
x.push(itDepends.value(-1));
}
var a = itDepends.computed(function() {
var z = 0;
for (var j = 0; j < dependenciesCount; j++) {
z += x[j]();
}
return z;
});
var b = itDepends.value(true);
var c = itDepends.computed(function() {
return b() ? a() : 0;
});
should work faster than scenariowith approximately the same performance as in the following scenario (see #68):
c.onChange(function() {});
b.write(false);
Example 2
Given the following definitions:
var x = [];
for (var j = 0; j < dependenciesCount; j++) {
x.push(itDepends.value(-1));
}
var a = itDepends.computed(function() {
var z = 0;
for (var j = 0; j < dependenciesCount; j++) {
z += x[j]();
}
return z;
});
var b = itDepends.value(6);
var c = itDepends.value(10);
var d = itDepends.computed(function() {
return b() * c() === 60 ? a() : 0;
});
var s = d.onChange(function() {});
There should be an ability to compare performance of certain scenarios (not versus KnockoutJS) For example I know at least 2 tests I want to write that way.
Given the following definitions:
the scenario:
should work
faster than scenariowith approximately the same performance as in the following scenario (see #68):Given the following definitions:
the scenario:
should work faster than scenario: