typescript - Error in sinon when I try to stub getter again -


when try stub getter again, have error:

typeerror: cannot redefine property: cqlfilter     @ function.defineproperty (<anonymous>) 

this part of test code:

const layer = new layer(); const cqlfilterstub = sinon.stub(layer, "cqlfilter"); cqlfilterstub.get(() => "test"); // error occurs in line cqlfilterstub.get(() => null); 


Comments

Popular posts from this blog

cookies - Yii2 Advanced - Share session between frontend and mainsite (duplicate of frontend for www) -

angular - password and confirm password field validation angular2 reactive forms -

php - Permission denied. Laravel linux server -