<div dir="ltr"><span style="color:rgb(51,51,51);font-family:Georgia,"Times New Roman",Times,serif;font-size:16px">> The point is not how to write assertions, but how to replace implementation of </span><code style="box-sizing:border-box;font-family:Menlo,Monaco,Consolas,"Courier New",monospace;font-size:14px;padding:2px 4px;color:rgb(199,37,78);background-color:rgb(249,242,244);border-radius:4px;line-height:18px">compoteGraph</code><span style="color:rgb(51,51,51);font-family:Georgia,"Times New Roman",Times,serif;font-size:16px"> </span><div><span style="color:rgb(51,51,51);font-family:Georgia,"Times New Roman",Times,serif;font-size:16px">> with some other that would return something else for sake of testing only one module instead of all deeply dependant modules.</span><br><div><span style="color:rgb(51,51,51);font-family:Georgia,"Times New Roman",Times,serif;font-size:16px"><br></span></div><div><span style="color:rgb(51,51,51);font-family:Georgia,"Times New Roman",Times,serif;font-size:16px">What do you mean by "replace implementation"?</span></div><div><span style="color:rgb(51,51,51);font-family:Georgia,"Times New Roman",Times,serif;font-size:16px"><br></span></div><div><span style="color:rgb(51,51,51);font-family:Georgia,"Times New Roman",Times,serif;font-size:16px">Are you trying to verify if `compoteGraph` returns what you are expecting the function to return? </span></div><div><span style="color:rgb(51,51,51);font-family:Georgia,"Times New Roman",Times,serif;font-size:16px"><br></span></div><div><span style="color:rgb(51,51,51);font-family:Georgia,"Times New Roman",Times,serif;font-size:16px">If that is the case, how do you know what `compoteGraph` is expected to return in the first instance? </span></div><div><span style="color:rgb(51,51,51);font-family:Georgia,"Times New Roman",Times,serif;font-size:16px"><br></span></div><div><span style="color:rgb(51,51,51);font-family:Georgia,"Times New Roman",Times,serif;font-size:16px">In general, it is not possible to predict the return value of a function without executing the function.</span></div></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, Jul 2, 2019 at 3:15 PM Adam Eisenreich <<a href="mailto:akxe@seznam.cz">akxe@seznam.cz</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div>The point is not how to write assertions, but how to replace implementation of `<span style="background-color:transparent;color:inherit;font-family:Menlo,Monaco,Consolas,"Courier New",monospace;font-size:14px;white-space:pre-wrap">compoteGraph</span><span style="background-color:transparent">` with some other that would return something else for sake of testing only one module instead of all deeply dependant modules.<br></span><br>I suppose that the user gesture might be solvable by starting browser with correct configuration. It isn't the easy plug-play style that javascript usually have, but that might be fine, as this isn't the most typical use case anyway.</div>_______________________________________________<br>
es-discuss mailing list<br>
<a href="mailto:es-discuss@mozilla.org" target="_blank">es-discuss@mozilla.org</a><br>
<a href="https://mail.mozilla.org/listinfo/es-discuss" rel="noreferrer" target="_blank">https://mail.mozilla.org/listinfo/es-discuss</a><br>
</blockquote></div>