New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Codecoverage fails: Cannot read property 'push' of undefined #547
Comments
Looks like this test is causing the problem. Will look at the details later: describe("two different dates are set to same when updating aggregate", function (done) {
var date = new Date();
var d1 = ko.observable(date);
var d2 = ko.observable(new Date(date + 1));
beforeEach(function(done) {
var dates = ko.observable([
ko.computed({ read: d1, write: d2 }),
ko.computed({
read: d2,
write: function(value) {
console.log(value);
d2(value);
}
})
]);
var aggr = ko.aggregate(dates);
aggr(new Date(date));
_.delay(done, 500);
});
it("should be", function() {
expect(d1().getTime()).toBe(date.getTime());
expect(d2().getTime()).toBe(date.getTime());
});
}); |
Perhaps it's a caching issue, try changing wallaby.js config file (even a space anywhere will do), restart wallaby and see if the issue goes away. I'm trying to create the sample to run your tests locally, but can't run it yet. One (most likely unrelated) thing I have noticed is that you are passing |
I have also reviewed few latest versions of wallaby and didn't find any changes that might affect this scenario, are you sure the test suite was running fine earlier? Perhaps you have changed something else in your project recently? |
Hi. Back now. Found out about it: A colleague added a new test which also passed when he added it - but restarting wallaby afterwords failed. That happens if a Running incrementally it is no problem, but when loading initially it fails with the error I gave you: describe("desc", function() {
it("duplicate", function() {
});
describe("duplicate", function() {
it("test", function () {
});
});
}); |
I don't know what the spec says, but tryjasmine.com doesn't bother complaining |
Great catch! Thanks a lot for isolating it. |
np. i fixed the names :) |
but thx for fixing that fast. and thanks for the great product. actually, I'm now writing tests :) |
@lcorneliussen Hehe, thanks! Glad to hear it makes testing easier for you. |
Issue description or question
I ran a working test set with a new version of wallaby. Still trying to find out, which test exactly causes the problem.
Wallaby.js configuration file
Code editor or IDE name and version
Visual Studio 2015 Update 1
OS name and version
Windows 10
The text was updated successfully, but these errors were encountered: