Consider the following snippet of my javascript function -
firstJs.prototype.SetSum=function(a,b){
var htmlToBind="<div>"+(a+b)+"</div>";
$('#setSum').html(htmlToBind);
};
Here setSum is a elementID in DOM.I would like to understand how will this function pass the unit testing done by Jasmine or Jest as and when the unit testing would run it will not find the 'setSum' in DOM hence fail the test case.I am a rookie in test cases